Closed astudnev closed 7 years ago
Look at the temporary decision. I'm using clang instead of gcc@4.9
diff --git a/lib/nmatrix/mkmf.rb b/lib/nmatrix/mkmf.rb
index 544e3af..6a58341 100644
--- a/lib/nmatrix/mkmf.rb
+++ b/lib/nmatrix/mkmf.rb
@@ -38,6 +38,11 @@ def find_newer_gplusplus #:nodoc:
puts ver
return CONFIG['CXX']
end
+
+ gpp = 'g++'
+ if (result = `which #{gpp}`)
+ return (CONFIG['CXX'] = gpp)
+ end
false
end
@rssdev10 , it did not help, it finds the same g++ ( 4.9 )
yes, you are right. Actually I removed gcc 4.9. Right now I have gcc without version which is identified as
gcc -v
Configured with: --prefix=/Library/Developer/CommandLineTools/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
Apple LLVM version 8.0.0 (clang-800.0.42.1)
You can remove a code before my patch if need to save gcc 4.9. In any case this method must be rewritten.
Use clang and clang++ on OSX.
Duplicates #591; closing.
Sorry, but the issue 426 still exists. I fail to install nmatrix on MacOS
gem install nmatrix
fails with error:
compiling nmatrix.cpp g++-4.9: error: unrecognized command line option '-Wdivision-by-zero' g++-4.9: error: unrecognized command line option '-Wextra-tokens' make: *** [nmatrix.o] Error 1
configuration:
ruby -v -rrbconfig -e 'puts RbConfig::MAKEFILE_CONFIG["CXX"]' ruby 2.3.3p222 (2016-11-21 revision 56859) [x86_64-darwin16] g++
Full log: