sighingnow / libclang

(Unofficial) Release libclang (clang.cindex) on pypi.
https://pypi.org/project/libclang
Other
81 stars 21 forks source link

Add macOS aarch64 wheel #15

Closed TylerADavis closed 2 years ago

TylerADavis commented 2 years ago

I am trying to install a TF Nightly wheel that I built from source, and it seems that TensorFlow requires libclang>=9.0.1. However, there is not an aarch64 or universal2 macOS wheel available for download on pypi, so my pip install is failing.

I see in #11 that there is now a Linux wheel, and it would be great to have one for macOS as well. I'd be glad to help out, but I'm not sure what generating the new wheel would require.

Steps taken:

❯ python3.9 -m venv ~/tensorflow_blank_39
❯ source ~/tensorflow_blank_39/bin/activate
❯ pip3 install --upgrade pip numpy wheel
Requirement already satisfied: pip in /Users/tylerdavis/tensorflow_blank_39/lib/python3.9/site-packages (21.2.3)
Collecting pip
  Using cached pip-21.3.1-py3-none-any.whl (1.7 MB)
Collecting numpy
  Using cached numpy-1.21.3-cp39-cp39-macosx_11_0_arm64.whl (12.4 MB)
Collecting wheel
  Using cached wheel-0.37.0-py2.py3-none-any.whl (35 kB)
Installing collected packages: wheel, pip, numpy
  Attempting uninstall: pip
    Found existing installation: pip 21.2.3
    Uninstalling pip-21.2.3:
      Successfully uninstalled pip-21.2.3
Successfully installed numpy-1.21.3 pip-21.3.1 wheel-0.37.0
❯ python3 install keras-preprocessing --no-deps
/Users/tylerdavis/tensorflow_blank_39/bin/python3: can't open file '/private/tmp/tensorflow_pkg/install': [Errno 2] No such file or directory
❯ python3 install keras-preprocessing --no-deps
❯ ls
tf_nightly-2.8.0-cp39-cp39-macosx_12_0_arm64.whl
❯ pip3 install keras-preprocessing --no-deps
Collecting keras-preprocessing
  Using cached Keras_Preprocessing-1.1.2-py2.py3-none-any.whl (42 kB)
Installing collected packages: keras-preprocessing
Successfully installed keras-preprocessing-1.1.2
❯ pip3 install ./tf_nightly-2.8.0-cp39-cp39-macosx_12_0_arm64.whl
Processing ./tf_nightly-2.8.0-cp39-cp39-macosx_12_0_arm64.whl
Collecting six>=1.12.0
  Using cached six-1.16.0-py2.py3-none-any.whl (11 kB)
Collecting wrapt>=1.11.0
  Using cached wrapt-1.13.3.tar.gz (48 kB)
  Preparing metadata (setup.py) ... done
Collecting astunparse>=1.6.0
  Using cached astunparse-1.6.3-py2.py3-none-any.whl (12 kB)
ERROR: Could not find a version that satisfies the requirement libclang>=9.0.1 (from tf-nightly) (from versions: none)
ERROR: No matching distribution found for libclang>=9.0.1
sighingnow commented 2 years ago

I have upload the macos arm64 wheel to pypi:

https://pypi.org/project/libclang/12.0.0/#files

I remember that I have tried in #7 but it is rejected by pypi at that time. Now it is available.

Thanks for bringing this issue out!

TylerADavis commented 2 years ago

Thanks! It installed without issue using pip.

sighingnow commented 2 years ago

Thanks for the feedback!