ifduyue / python-xxhash

Python Binding for xxHash
https://pypi.org/project/xxhash/
BSD 2-Clause "Simplified" License
376 stars 30 forks source link

Failed to create from source on MacOSX Big Sur (11.1) #44

Closed arjanz closed 2 years ago

arjanz commented 3 years ago

When trying to compile from source on MacOSX 11.1 I get the following error:

Running setup.py install for xxhash ... error
    ERROR: Command errored out with exit status 1:
     command: /Users/arjan/Development/py-substrate-interface/venv/bin/python3.9 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/2h/jl7dn8js7pbcqbm644pg0q700000gn/T/pip-install-5cdfodud/xxhash_d64eeb944ea843cb8f9ade53b9481153/setup.py'"'"'; __file__='"'"'/private/var/folders/2h/jl7dn8js7pbcqbm644pg0q700000gn/T/pip-install-5cdfodud/xxhash_d64eeb944ea843cb8f9ade53b9481153/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /private/var/folders/2h/jl7dn8js7pbcqbm644pg0q700000gn/T/pip-record-x3l8gs60/install-record.txt --single-version-externally-managed --compile --install-headers /Users/arjan/Development/py-substrate-interface/venv/include/site/python3.9/xxhash
         cwd: /private/var/folders/2h/jl7dn8js7pbcqbm644pg0q700000gn/T/pip-install-5cdfodud/xxhash_d64eeb944ea843cb8f9ade53b9481153/
    Complete output (16 lines):
    running install
    running build
    running build_py
    creating build
    creating build/lib.macosx-11-x86_64-3.9
    creating build/lib.macosx-11-x86_64-3.9/xxhash
    copying xxhash/__init__.py -> build/lib.macosx-11-x86_64-3.9/xxhash
    running build_ext
    building '_xxhash' extension
    creating build/temp.macosx-11-x86_64-3.9
    creating build/temp.macosx-11-x86_64-3.9/deps
    creating build/temp.macosx-11-x86_64-3.9/deps/xxhash
    creating build/temp.macosx-11-x86_64-3.9/src
    clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -I/usr/local/include -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -I/usr/local/opt/bzip2/include -I/usr/local/opt/zlib/include -Ideps/xxhash -I/usr/local/include -I/usr/local/opt/openssl@1.1/include -I/usr/local/opt/sqlite/include -I/usr/local/opt/tcl-tk/include -I/Users/arjan/Development/py-substrate-interface/venv/include -I/usr/local/Cellar/python@3.9/3.9.1_6/Frameworks/Python.framework/Versions/3.9/include/python3.9 -c deps/xxhash/xxhash.c -o build/temp.macosx-11-x86_64-3.9/deps/xxhash/xxhash.o
    clang-10: error: invalid version number in 'MACOSX_DEPLOYMENT_TARGET=11'
    error: command '/usr/local/opt/llvm/bin/clang' failed with exit code 1
ifduyue commented 3 years ago

No 3.9 wheels right now. See also #43

ifduyue commented 3 years ago

I have misread this issue.

What's the version of clang? I'm using 10.15.7 and clang --version is 12??

$ clang --version
Apple clang version 12.0.0 (clang-1200.0.32.27)
Target: x86_64-apple-darwin19.6.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin
ifduyue commented 2 years ago

New release 3.0.0 is on PyPI now.