-
Notifications
You must be signed in to change notification settings - Fork 1.2k
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
cann't install on MAC M1 #577
Comments
Hi, I've installed annoy on M1 successfully following the steps:
|
use python 3.9 |
would build wheel with unsupported tag ('cp39', 'cp39', 'macosx_11_0_arm64') |
I am getting the same error on a Mac M1, Python 3.9.10
|
As mentioned in #567 To solve this issue you
Then install annoy: |
@amayuelas Thanks for this clue. So that when I check with clang command. Found out the XCode user agreeement is not yet checked. The compilation failed with similar error. The reason is very unobvious. After checking the agreement, it works as expected. |
the error message like this:
Using legacy 'setup.py install' for annoy, since package 'wheel' is not installed.
Installing collected packages: annoy
Running setup.py install for annoy ... error
ERROR: Command errored out with exit status 1:
command: /Users/cooper/PycharmProjects/faq/venv/bin/python -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/np/pjvnrzpj65q2p4gv1pfh8nqc0000gn/T/pip-install-gf4q13ts/annoy_789593428b7643f98169824423d770ff/setup.py'"'"'; file='"'"'/private/var/folders/np/pjvnrzpj65q2p4gv1pfh8nqc0000gn/T/pip-install-gf4q13ts/annoy_789593428b7643f98169824423d770ff/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /private/var/folders/np/pjvnrzpj65q2p4gv1pfh8nqc0000gn/T/pip-record-dcdyq3od/install-record.txt --single-version-externally-managed --compile --install-headers /Users/cooper/PycharmProjects/faq/venv/include/site/python3.8/annoy
cwd: /private/var/folders/np/pjvnrzpj65q2p4gv1pfh8nqc0000gn/T/pip-install-gf4q13ts/annoy_789593428b7643f98169824423d770ff/
Complete output (15 lines):
WARNING: The wheel package is not available.
running install
running build
running build_py
creating build
creating build/lib.macosx-10.14-x86_64-3.8
creating build/lib.macosx-10.14-x86_64-3.8/annoy
copying annoy/init.py -> build/lib.macosx-10.14-x86_64-3.8/annoy
running build_ext
building 'annoy.annoylib' extension
creating build/temp.macosx-10.14-x86_64-3.8
creating build/temp.macosx-10.14-x86_64-3.8/src
clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -iwithsysroot/System/Library/Frameworks/System.framework/PrivateHeaders -iwithsysroot/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.8/Headers -arch arm64 -arch x86_64 -Werror=implicit-function-declaration -I/Users/cooper/PycharmProjects/faq/venv/include -I/Library/Developer/CommandLineTools/Library/Frameworks/Python3.framework/Versions/3.8/include/python3.8 -c src/annoymodule.cc -o build/temp.macosx-10.14-x86_64-3.8/src/annoymodule.o -D_CRT_SECURE_NO_WARNINGS -march=native -O3 -ffast-math -fno-associative-math -std=c++11 -mmacosx-version-min=10.9
clang: error: the clang compiler does not support '-march=native'
error: command 'clang' failed with exit status 1
----------------------------------------
ERROR: Command errored out with exit status 1: /Users/cooper/PycharmProjects/faq/venv/bin/python -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/np/pjvnrzpj65q2p4gv1pfh8nqc0000gn/T/pip-install-gf4q13ts/annoy_789593428b7643f98169824423d770ff/setup.py'"'"'; file='"'"'/private/var/folders/np/pjvnrzpj65q2p4gv1pfh8nqc0000gn/T/pip-install-gf4q13ts/annoy_789593428b7643f98169824423d770ff/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /private/var/folders/np/pjvnrzpj65q2p4gv1pfh8nqc0000gn/T/pip-record-dcdyq3od/install-record.txt --single-version-externally-managed --compile --install-headers /Users/cooper/PycharmProjects/faq/venv/include/site/python3.8/annoy Check the logs for full command output.
my computer is MAC M1, how to install,thanks
The text was updated successfully, but these errors were encountered: