Skip to content
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

ToT wants arm64e or arm64 to build on Apple silicon, but pypi version is fine #400

Open
lenzo-ka opened this issue Oct 23, 2024 · 2 comments

Comments

@lenzo-ka
Copy link
Contributor

The pypi version instealls fine on macOS on Apple Silicon, but when building from source:

python
Python 3.12.4 (main, Jul  8 2024, 10:17:47) [Clang 15.0.0 (clang-1500.3.9.4)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import pocketsphinx
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File ".../ve_slab/lib/python3.12/site-packages/pocketsphinx/__init__.py", line 41, in <module>
    from . import _pocketsphinx as pocketsphinx  # noqa: F401
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ImportError: dlopen(.../ve_slab/lib/python3.12/site-packages/pocketsphinx/_pocketsphinx.cpython-312-darwin.so, 0x0002): tried: '.../ve_slab/lib/python3.12/site-packages/pocketsphinx/_pocketsphinx.cpython-312-darwin.so' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64e' or 'arm64')), '..../ve_slab/lib/python3.12/site-packages/pocketsphinx/_pocketsphinx.cpython-312-darwin.so' (no such file), '...../ve_slab/lib/python3.12/site-packages/pocketsphinx/_pocketsphinx.cpython-312-darwin.so' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64e' or 'arm64'))
@lenzo-ka
Copy link
Contributor Author

When doing pip install . it did not complain.

To fix it locally,

arch -arm64 python -m pip install .

does the trick.

@dhdaines
Copy link
Contributor

Thanks Kevin! I must have misconfigured cibuildwheel somehow - is it the case that the universal builds are not really universal?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants