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
Apple M1 support #33
Comments
It should build on Apple M1, however we do not yet have binary wheels pre-built for Apple M1 so it will be necessary to build, which requires xcode and may take a few minutes. What error are you getting? The current release 0.1.18 on PyPI has an issue with the zlib dependency --- a new release 0.1.19 should be available within an hour that solves the zlib issue (but you will still need to build on M1). You can also just |
below is the error I am getting
Collecting git+https://github.com/google/tensorstore × Building wheel for tensorstore (pyproject.toml) did not run successfully.
note: This error originates from a subprocess, and is likely not a problem with pip. |
Thanks --- we'll look into that issue. Can you share your version of xcode and macos ? |
With Python 3.8.9 on macOS 12.2.1 and xcode 13.3.1 I am able to build it successfully. |
my python version is 3.8.13, macOS is 12.2.1 and Xcode command line utils is 13.3.1 |
Another data point; installation works for me on MacOS 12.3.1 and xcode 13.2.1 $ python3 --version
Python 3.8.9
$ uname -v
Darwin Kernel Version 21.4.0: Fri Mar 18 00:46:32 PDT 2022; root:xnu-8020.101.4~15/RELEASE_ARM64_T6000
$ clang --version
Apple clang version 13.1.6 (clang-1316.0.21.2.3)
Target: arm64-apple-darwin21.4.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin You could try a non pip build: git clone https://github.com/google/tensorstore.git
cd tensorstore
./bazelisk.py build //tensorstore |
build was successful with the Bazelisk.py. Do I need to do anything else to install the package after build? |
Building just the Until we can sort out the AOM build failure, one workaround is to disable the tensorstore/tensorstore/driver/BUILD Line 13 in 7f45003
Then you can install the package with:
from the root of the checkout. |
Before you move on, try this:
If that fails, yeah, remove the line and do as jeremy suggests. |
yep..that worked |
I tried to install the xcode 13.3.1 command line tools, but that doesn't appear to have changed anything for me. Looking at this, the missing symbol is from the file This file should be selected into the build when the config Nevertheless it would be nice to know which You can probably get the full build working by forcing it to build with
|
I ll give this a try |
getting the following error: Building wheels for collected packages: tensorstore × Building wheel for tensorstore (pyproject.toml) did not run successfully. note: This error originates from a subprocess, and is likely not a problem with pip. |
any updates on a direct fix for the build problem? |
The issue described in #33 (comment) appears to be a problem in Bazel itself, since it is considering those system headers to be undeclared inclusions. As a starting point, if you can try just building It is also possible that upgrading to a newer version of However, there is good news: we are now able to build macOS arm64 binary packages on Github actions (expected to be released in the next couple days), which in many cases will eliminate the need to build at all and thereby avoid possible build issues. In fact you can download a prerelease version of the binary packages from here: https://github.com/google/tensorstore/actions/runs/2763457110 Download and extract the arm64 zip file, and then you can install the package for your Python version using |
As of 0.1.22, there are now macOS arm64 binary packages available on PyPI. |
I believe the "undeclared inclusions" issue reported by @ibulu may be a Bazel bug that is fixed simply by deleting the bazel cache:
|
is it possible to install on Apple M1? I wasn't able to install via pip
The text was updated successfully, but these errors were encountered: