Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problems installing in macos 10.12.6 #8

Open
guicalman opened this issue Sep 22, 2017 · 5 comments
Open

Problems installing in macos 10.12.6 #8

guicalman opened this issue Sep 22, 2017 · 5 comments

Comments

@guicalman
Copy link

Hello,

I am following the instructions

Command executed after installing brew install blass

calderon-ml:macau calderon$ export CPPFLAGS=-I/usr/local/Cellar/openblas/include
calderon-ml:macau calderon$ export LDFLAGS=-L/usr/local/Cellar/openblas/lib
calderon-ml:macau calderon$ CC=g++-5 CXX=g++-5 python3 setup.py install
unable to execute 'g++-5': No such file or directory
libopenblas compile error (please install OpenBLAS)
unable to execute 'g++-5': No such file or directory
libopenblas lapack compile error (please install OpenBLAS)
unable to execute 'g++-5': No such file or directory
libopenblas compile error (please install OpenBLAS)
unable to execute 'g++-5': No such file or directory
libopenblas lapack compile error (please install OpenBLAS)
OpenBLAS or standard BLAS not found. Please install.
calderon-ml:macau calderon$ 

But I get the following error

unable to execute 'g++-5': No such file or directory
libopenblas compile error (please install OpenBLAS)
unable to execute 'g++-5': No such file or directory
libopenblas lapack compile error (please install OpenBLAS)
unable to execute 'g++-5': No such file or directory
libopenblas compile error (please install OpenBLAS)
unable to execute 'g++-5': No such file or directory
libopenblas lapack compile error (please install OpenBLAS)
OpenBLAS or standard BLAS not found. Please install.
calderon-ml:macau calderon$ 

Thank you very much for your help.

@jaak-s
Copy link
Owner

jaak-s commented Sep 22, 2017

You would need to execute these two commands:

brew install homebrew/science/openblas
brew install gcc

This should give you GNU version of g++, which is needed instead of the default (clang one). Let me know if this solved your issue.

@guicalman
Copy link
Author

Thank you for your response, I reinstalled openblas and gcc, but still have the same problem :'(

calderon-ml:macau calderon$ export LDFLAGS=-L/usr/local/opt/openblas/lib
calderon-ml:macau calderon$ export CPPFLAGS=-I/usr/local/opt/openblas/include
calderon-ml:macau calderon$ CC=g++-5 CXX=g++-5 python3 setup.py install
unable to execute 'g++-5': No such file or directory
libopenblas compile error (please install OpenBLAS)
unable to execute 'g++-5': No such file or directory
libopenblas lapack compile error (please install OpenBLAS)
unable to execute 'g++-5': No such file or directory
libopenblas compile error (please install OpenBLAS)
unable to execute 'g++-5': No such file or directory
libopenblas lapack compile error (please install OpenBLAS)
OpenBLAS or standard BLAS not found. Please install.

@jaak-s
Copy link
Owner

jaak-s commented Sep 22, 2017

You can just try the command

python3 setup.py install

If it fails let me know the error and what is the g++ version: g++ --version

@guicalman
Copy link
Author

Unfortunately I still have problems, here is the information you required:

Error

calderon-ml:macau calderon$ python3 setup.py install
ld: warning: directory not found for option '-L/opt/OpenBLAS/lib'
ld: warning: directory not found for option '-L/usr/lib/openblas-base'
ld: warning: directory not found for option '-L/usr/local/opt/gcc/lib/gcc/5'
ld: library not found for -lgfortran
clang: error: linker command failed with exit code 1 (use -v to see invocation)
libopenblas link error (please install OpenBLAS)
ld: warning: directory not found for option '-L/opt/OpenBLAS/lib'
ld: warning: directory not found for option '-L/usr/lib/openblas-base'
ld: warning: directory not found for option '-L/usr/local/opt/gcc/lib/gcc/5'
ld: library not found for -lgfortran
clang: error: linker command failed with exit code 1 (use -v to see invocation)
libopenblas lapack link error (please install OpenBLAS)
ld: warning: directory not found for option '-L/opt/OpenBLAS/lib'
ld: warning: directory not found for option '-L/usr/lib/openblas-base'
ld: warning: directory not found for option '-L/usr/local/opt/gcc/lib/gcc/5'
ld: warning: directory not found for option '-L/opt/OpenBLAS/lib'
ld: warning: directory not found for option '-L/usr/lib/openblas-base'
ld: warning: directory not found for option '-L/usr/local/opt/gcc/lib/gcc/5'
Standard BLAS found.
running install
running bdist_egg
running egg_info
writing python/macau.egg-info/PKG-INFO
writing dependency_links to python/macau.egg-info/dependency_links.txt
writing requirements to python/macau.egg-info/requires.txt
writing top-level names to python/macau.egg-info/top_level.txt
reading manifest file 'python/macau.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'python/macau.egg-info/SOURCES.txt'
installing library code to build/bdist.macosx-10.12-x86_64/egg
running build_clib
clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/usr/local/opt/openblas/include -fopenmp -O3 -fstrict-aliasing -std=c++11 -Ilib/macau-cpp -Ilib/eigen3.3.3 -Ilib/libfastsparse -I/usr/local/lib/python3.6/site-packages/numpy/core/include -I/usr/local/Cellar/python3/3.6.2/Frameworks/Python.framework/Versions/3.6/include/python3.6m -I/usr/local/include -I/usr/local/opt/openblas/include -c lib/macau-cpp/bpmfutils.cpp -o build/temp.macosx-10.12-x86_64-3.6/lib/macau-cpp/bpmfutils.o
clang: error: unsupported option '-fopenmp'
error: command 'clang' failed with exit status 1

g++ version

calderon-ml:macau calderon$ g++ --version
Configured with: --prefix=/Library/Developer/CommandLineTools/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
Apple LLVM version 9.0.0 (clang-900.0.37)
Target: x86_64-apple-darwin16.7.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin

Thank you for your help.

@jaak-s
Copy link
Owner

jaak-s commented Sep 22, 2017

The g++ version means that your brew failed installing gcc (as it currently shows the default Apple clang instead on GNU gcc). Unfortunately with clang Macau does not work.

Can you try installing gcc again from brew. And check if it reports any errors (maybe you need to remove the previous version before hand).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants