安装时出现段错误 11 ruby 3
segment fault 11 when install ruby 3
我需要在我的机器上安装 ruby 3.0.0 来升级我的 ROR 应用程序 gems,我使用 RVM 作为版本管理但是当我写 RVM install 3.0.0 时我有这个错误
Error running '__rvm_make -j4',
please read /Users/hadii/.rvm/log/1620191440_ruby-3.0.0/make.log
There has been an error while running makes. Halting the installation.
当我跟踪 make.log 文件时,我发现了这个:
tail /Users/hadii/.rvm/log/1620191440_ruby-3.0.0/make.log
./revision.h unchanged
compiling version.c
linking miniruby
warning: no debug symbols in executable (-arch x86_64)
generating x86_64-darwin19-fake.rb
x86_64-darwin19-fake.rb updated
warning: no debug symbols in executable (-arch x86_64)
make: *** [exe/ruby] Segmentation fault: 11
make: *** Deleting file `exe/ruby'
++++++++++++ support:384 @__rvm_make:0> return 2
我 google 经常做很多事情,比如卸载 RVM,ruby 从我的机器上重新安装,重新配置 RVM 使用这个命令:
RVM get head
RVM get master
我什至遵循这个 link 但没有任何改变,甚至我尝试安装更新版本的 ruby-like 3.0.1 甚至尝试这个命令
RVM install "ruby-3.0.0"
但是我无法安装任何新版本的ruby,请帮助我
我在 iMac 上工作,我的 os 版本是 Catalina
ruby 现在可用的版本 2.7.1
Rails 5.2.5
rvm 1.29.12
更新:
我尝试手动安装 ruby 并按照此操作 tutorials 但收到此错误消息
BASERUBY = /Users/hadii/.rvm/rubies/ruby-2.7.1/bin/ruby --disable=gems
CC = clang -fdeclspec
LD = clang
LDSHARED = clang -fdeclspec -dynamiclib
CFLAGS = -O3 -ggdb3 -Wall -Wextra -Wdeprecated-declarations -Wdivision-by-zero -Wimplicit-function-declaration -Wimplicit-int -Wpointer-arith -Wshorten-64-to-32 -Wwrite-strings -Wmissing-noreturn -Wno-constant-logical-operand -Wno-long-long -Wno-missing-field-initializers -Wno-overlength-strings -Wno-parentheses-equality -Wno-self-assign -Wno-tautological-compare -Wno-unused-parameter -Wno-unused-value -Wunused-variable -Wextra-tokens -std=gnu99 -pipe
XCFLAGS = -D_FORTIFY_SOURCE=2 -fstack-protector-strong -fno-strict-overflow -fvisibility=hidden -DRUBY_EXPORT -fPIE -I. -I.ext/include/x86_64-darwin19 -I./include -I. -I./enc/unicode/12.1.0
CPPFLAGS = -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE -D_DARWIN_UNLIMITED_SELECT -D_REENTRANT
DLDFLAGS = -Wl,-undefined,dynamic_lookup -Wl,-multiply_defined,suppress -fstack-protector-strong -Wl,-pie -framework Security -framework Foundation
SOLIBS = -lpthread -lgmp -ldl -lobjc
LANG = en_US.UTF-8
LC_ALL =
LC_CTYPE =
MFLAGS =
Apple clang version 11.0.0 (clang-1100.0.33.8)
Target: x86_64-apple-darwin19.6.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
./revision.h unchanged
make: *** [exe/ruby] Segmentation fault: 11
make: *** Deleting file `exe/ruby'
经过长时间的谷歌搜索并遇到了很多我之前解释过的问题,我发现了这个 link
解释了这三个命令 有助于解决这些问题。
$ sudo rm -rf /Library/Developer/CommandLineTools
$ xcode-select --install
$ sudo xcode-select -s /Library/Developer/CommandLineTools
我需要在我的机器上安装 ruby 3.0.0 来升级我的 ROR 应用程序 gems,我使用 RVM 作为版本管理但是当我写 RVM install 3.0.0 时我有这个错误
Error running '__rvm_make -j4',
please read /Users/hadii/.rvm/log/1620191440_ruby-3.0.0/make.log
There has been an error while running makes. Halting the installation.
当我跟踪 make.log 文件时,我发现了这个:
tail /Users/hadii/.rvm/log/1620191440_ruby-3.0.0/make.log
./revision.h unchanged
compiling version.c
linking miniruby
warning: no debug symbols in executable (-arch x86_64)
generating x86_64-darwin19-fake.rb
x86_64-darwin19-fake.rb updated
warning: no debug symbols in executable (-arch x86_64)
make: *** [exe/ruby] Segmentation fault: 11
make: *** Deleting file `exe/ruby'
++++++++++++ support:384 @__rvm_make:0> return 2
我 google 经常做很多事情,比如卸载 RVM,ruby 从我的机器上重新安装,重新配置 RVM 使用这个命令:
RVM get head
RVM get master
我什至遵循这个 link 但没有任何改变,甚至我尝试安装更新版本的 ruby-like 3.0.1 甚至尝试这个命令
RVM install "ruby-3.0.0"
但是我无法安装任何新版本的ruby,请帮助我
我在 iMac 上工作,我的 os 版本是 Catalina
ruby 现在可用的版本 2.7.1
Rails 5.2.5
rvm 1.29.12
更新:
我尝试手动安装 ruby 并按照此操作 tutorials 但收到此错误消息
BASERUBY = /Users/hadii/.rvm/rubies/ruby-2.7.1/bin/ruby --disable=gems
CC = clang -fdeclspec
LD = clang
LDSHARED = clang -fdeclspec -dynamiclib
CFLAGS = -O3 -ggdb3 -Wall -Wextra -Wdeprecated-declarations -Wdivision-by-zero -Wimplicit-function-declaration -Wimplicit-int -Wpointer-arith -Wshorten-64-to-32 -Wwrite-strings -Wmissing-noreturn -Wno-constant-logical-operand -Wno-long-long -Wno-missing-field-initializers -Wno-overlength-strings -Wno-parentheses-equality -Wno-self-assign -Wno-tautological-compare -Wno-unused-parameter -Wno-unused-value -Wunused-variable -Wextra-tokens -std=gnu99 -pipe
XCFLAGS = -D_FORTIFY_SOURCE=2 -fstack-protector-strong -fno-strict-overflow -fvisibility=hidden -DRUBY_EXPORT -fPIE -I. -I.ext/include/x86_64-darwin19 -I./include -I. -I./enc/unicode/12.1.0
CPPFLAGS = -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE -D_DARWIN_UNLIMITED_SELECT -D_REENTRANT
DLDFLAGS = -Wl,-undefined,dynamic_lookup -Wl,-multiply_defined,suppress -fstack-protector-strong -Wl,-pie -framework Security -framework Foundation
SOLIBS = -lpthread -lgmp -ldl -lobjc
LANG = en_US.UTF-8
LC_ALL =
LC_CTYPE =
MFLAGS =
Apple clang version 11.0.0 (clang-1100.0.33.8)
Target: x86_64-apple-darwin19.6.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
./revision.h unchanged
make: *** [exe/ruby] Segmentation fault: 11
make: *** Deleting file `exe/ruby'
经过长时间的谷歌搜索并遇到了很多我之前解释过的问题,我发现了这个 link 解释了这三个命令 有助于解决这些问题。
$ sudo rm -rf /Library/Developer/CommandLineTools
$ xcode-select --install
$ sudo xcode-select -s /Library/Developer/CommandLineTools