I tried to install mini_racer-0.6.2, either using gem or bundle, and got the following error log. It seems like an issue of compiler ldflags, and I'm wondering whether I can manually customize the flags by replacing with -std=c++11. Or is there anyway else to fix this issue? Thanks!
current directory: /Users/kchen/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/mini_racer-0.6.2/ext/mini_racer_extension
/Users/kchen/.rbenv/versions/3.0.2/bin/ruby -I /Users/kchen/.rbenv/versions/3.0.2/lib/ruby/3.0.0 -r ./siteconf20220524-91238-bi0vse.rb extconf.rb
checking for -lpthread... yes
checking for -lobjc... yes
creating Makefile
current directory: /Users/kchen/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/mini_racer-0.6.2/ext/mini_racer_extension
make DESTDIR\= clean
current directory: /Users/kchen/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/mini_racer-0.6.2/ext/mini_racer_extension
make DESTDIR\=
compiling mini_racer_extension.cc
linking shared-object mini_racer_extension.bundle
g++-11: error: unrecognized command-line option '-stdlib=libc++'
make: *** [mini_racer_extension.bundle] Error 1
make failed, exit code 2
The gem environment I use is show below.
RubyGems Environment:
- RUBYGEMS VERSION: 3.2.22
- RUBY VERSION: 3.0.2 (2021-07-07 patchlevel 107) [x86_64-darwin21]
- INSTALLATION DIRECTORY: /Users/kchen/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0
- USER INSTALLATION DIRECTORY: /Users/kchen/.gem/ruby/3.0.0
- RUBY EXECUTABLE: /Users/kchen/.rbenv/versions/3.0.2/bin/ruby
- GIT EXECUTABLE: /Library/Developer/CommandLineTools/usr/bin/git
- EXECUTABLE DIRECTORY: /Users/kchen/.rbenv/versions/3.0.2/bin
- SPEC CACHE DIRECTORY: /Users/kchen/.gem/specs
- SYSTEM CONFIGURATION DIRECTORY: /Users/kchen/.rbenv/versions/3.0.2/etc
- RUBYGEMS PLATFORMS:
- ruby
- x86_64-darwin-21
- GEM PATHS:
- /Users/kchen/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0
- /Users/kchen/.gem/ruby/3.0.0
- GEM CONFIGURATION:
- :update_sources => true
- :verbose => true
- :backtrace => false
- :bulk_threshold => 1000
- REMOTE SOURCES:
- https://rubygems.org/
- SHELL PATH:
- /Users/kchen/.rbenv/versions/3.0.2/bin
- /usr/local/Cellar/rbenv/1.2.0/libexec
- /Users/kchen/.gem/ruby/3.0.2/bin
- /Users/kchen/.rbenv/shims
- /Applications/Julia-1.5.app/Contents/Resources/julia/bin
- /Users/kchen/miniconda3/bin
- /Users/kchen/miniconda3/condabin
- /Library/Developer/CommandLineTools/usr/bin
- /usr/local/opt/llvm/bin
- /usr/local/opt/ruby/bin
- /usr/local/lib/ruby/gems/3.0.2/bin
- /Users/kchen/.rbenv/shims
- /usr/local/opt/ruby/bin
- /usr/local/go/bin
- /Applications/workbench/bin_macosx64
- /usr/local/texlive/2018/bin/x86_64-darwin
- /Users/kchen/install/linux-19.2.0/tools/perf
- /usr/local/bin
- /usr/bin
- /bin
- /usr/sbin
- /sbin
- /Library/TeX/texbin
- /opt/X11/bin
I tried to install
mini_racer-0.6.2, either using gem or bundle, and got the following error log. It seems like an issue of compiler ldflags, and I'm wondering whether I can manually customize the flags by replacing with-std=c++11. Or is there anyway else to fix this issue? Thanks!The gem environment I use is show below.