From 91280b4c0b3ec0721a8f3ba09a1cc9f5ca56c238 Mon Sep 17 00:00:00 2001 From: Valentin Bartenev Date: Sun, 9 Aug 2020 01:00:44 +0300 Subject: [PATCH] Ruby: fixed gem mount paths. The gem paths must depend on the specified interpreter. Also, gemdir looks redundant as it's already included in Gem.default_path(). --- auto/modules/ruby | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/auto/modules/ruby b/auto/modules/ruby index bf628935..c1444f07 100644 --- a/auto/modules/ruby +++ b/auto/modules/ruby @@ -62,8 +62,8 @@ if /bin/sh -c "$NXT_RUBY -v" >> $NXT_AUTOCONF_ERR 2>&1; then NXT_RUBY_LIBDIR=`$NXT_RUBY -rrbconfig -e 'print RbConfig::CONFIG["rubylibdir"]'` NXT_RUBY_TOPDIR=`$NXT_RUBY -rrbconfig -e 'print RbConfig::CONFIG["topdir"]'` NXT_RUBY_PREFIXDIR=`$NXT_RUBY -rrbconfig -e 'print RbConfig::CONFIG["rubylibprefix"]'` - NXT_RUBY_GEMDIR=`gem environment gemdir` - NXT_RUBY_GEMPATH=`gem environment gempath` + + NXT_RUBY_GEMPATH=`$NXT_RUBY -rrubygems -e 'print Gem.default_path().join(":")'` NXT_RUBY_INCPATH="-I$NXT_RUBY_ARCHHDRDIR -I$NXT_RUBY_RUBYHDRDIR" @@ -163,8 +163,6 @@ static const nxt_fs_mount_t nxt_ruby_mounts[] = { (u_char *) "bind", NXT_MS_BIND | NXT_MS_REC, NULL}, {(u_char *) "$NXT_RUBY_LIBDIR", (u_char *) "$NXT_RUBY_LIBDIR", (u_char *) "bind", NXT_MS_BIND | NXT_MS_REC, NULL}, - {(u_char *) "$NXT_RUBY_GEMDIR", (u_char *) "$NXT_RUBY_GEMDIR", - (u_char *) "bind", NXT_MS_BIND | NXT_MS_REC, NULL}, {(u_char *) "$NXT_RUBY_TOPDIR", (u_char *) "$NXT_RUBY_TOPDIR", (u_char *) "bind", NXT_MS_BIND | NXT_MS_REC, NULL}, {(u_char *) "$NXT_RUBY_PREFIXDIR", (u_char *) "$NXT_RUBY_PREFIXDIR",