the-virtual-brain / tvb-gdist

Geodesic Library (adaptation by TVB Team)
Other
48 stars 30 forks source link

PyPI wheel installs incorrect architecture for macOS on M1 #72

Open maedoc opened 2 years ago

maedoc commented 2 years ago

A pip install tvb-gdist on macOS in an arm64 environment, works but unable to import,

---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
/var/folders/22/7cxnw94d2bq3cw98w7px74w40000gn/T/ipykernel_2570/3461558562.py in <module>
----> 1 import gdist

ImportError: dlopen(/Users/duke/miniforge3/lib/python3.9/site-packages/gdist.cpython-39-darwin.so, 0x0002): tried: '/Users/duke/miniforge3/lib/python3.9/site-packages/gdist.cpython-39-darwin.so' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64e'))

When I build and install from source, generating the wheels, the folder name now includes the architecture, and it would be helpful to upload wheels for this.

liadomide commented 2 years ago

Is the conda-forge pack for tvb-gdist working better for M1, or is the same ?

maedoc commented 2 years ago

At least it refuses to install. Conda has an explicit notion of osx-arm64 and excludes the prebuilt conda packages. When I download one of them anyway, I can see they are built for x86_64, not arm64,

% file gdist.cpython-38-darwin.so 
gdist.cpython-38-darwin.so: Mach-O 64-bit bundle x86_64