Open loicsacre opened 1 year ago
It looks like the following line indicates the cause
clang: error: unsupported option '-fopenmp'
I think openmp
must be installed in the system (although the package description does not say that)
Thank you for answer. For linux I needed to install gfortran
(see https://github.com/QUVA-Lab/escnn/issues/21#issuecomment-1356315791).
For MacOs, I will test it later and will keep you informed
Though the issue is closed, this might help some users:
on macOS (M1 pro chip), even after installing gcc via homebrew, the gcc
command is an alias to clang.
Symlinked gcc
to /opt/homebrew/bin/gcc-12
as follows:
cd /opt/homebrew/bin
ln -s gcc-12 gcc
Then CC=gcc pip3 install py3nj
installs the package without errors. CC=gcc python setup.py install
also works to build from source.
That's a workaround as I couldn't manage to make the installation work with clang.
Thank you @momierr for instruction. I made a pull-request readme.md https://github.com/fujiisoup/py3nj/blob/edc1dd18cdb0962487e79e0f85759ca7992cdda1/README.md?plain=1#L56-L68
I have no macOSs and am not able to confirm, but do you think the above description is fine? or if you suggest any alternatives, I will adopt it.
It would be better to mention that it is valid for macOS running on M1 CPU. Otherwise the instructions are fine!
Whenever I am trying to install the package with pip or from source, using Python3.7 or 3.8, on MacOsX 10.9 (x86_64) or Ubuntu 20, I am getting error while building the wheel for
py3nj
.Here are some examples of the error: ubuntu-error.txt macos-error.txt
I have also tried the solution proposed in https://github.com/fujiisoup/py3nj/issues/10#issuecomment-853030283 for MacOs, without success...
env CC=/usr/local/Cellar/gcc/11.2.0_3/bin/gcc-11 pip install py3nj
PS: I need to install this package for using https://github.com/QUVA-Lab/escnn