Skip to content

ImportError: dlopen(...c_uamqp.cpython-310-darwin.so): mach-o file, incompatible architecture (have 'x86_64', need 'arm64e') #284

@JrtPec

Description

@JrtPec

I have a Mac with M1-processor, so as long as not all Python packages are published as arm64 or universal binaries I have to run Python in emulated mode under Rosetta 2.

So when I saw that uamqp was released as universal binary, I gave it a go. But it still fails like I've installed it for the wrong architecture...

  • MacBook Pro M1
  • macOS Monterey 12.0.1
  • Python 3.10.0 installed through Brew on arm64 (arch -arm64 brew install python@3.10)
  • pip install uamqp in my Py3.10 venv installs uamqp-1.4.3-cp310-cp310-macosx_10_9_universal2.whl
ImportError: dlopen(venv_arm/lib/python3.10/site-packages/uamqp/c_uamqp.cpython-310-darwin.so, 0x0002): tried: 'venv_arm/lib/python3.10/site-packages/uamqp/c_uamqp.cpython-310-darwin.so' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64e')), '/usr/local/lib/c_uamqp.cpython-310-darwin.so' (no such file), '/usr/lib/c_uamqp.cpython-310-darwin.so' (no such file)

So when I install the same package under Python 3.10.0 installed through my x86_64 version of brew, it works just fine.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions