-
-
Notifications
You must be signed in to change notification settings - Fork 30
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
Publish a platform-specific wheel for Apple M1 (macOS ARM64) on PyPI #207
Comments
It's an interesting idea but until GitHub adds respective VMs to GHA, there's nothing we can do about this. So for now the users will have to install ansible-pylibssh from the sdist. Refs: |
Well for me even building it locally does not work.
|
Seeing the same error after installing libssh (via brew) and soft linking libssh into command line tools (ref). I see the comment to "install ansible-pylibssh from the sdist"; can anyone provide detail on it? I am only trying to install ansible-pylibssh because it a dependency of the ansible.netcommon collection. :( |
@l3ender @radokristof I was able to build locally with the correct compiler flags exported, no symlink required. Procedure. |
@dmacduff you shouldn't need to go through the contributor path (using tox etc.) |
@webknjaz Brilliant! I spun up a new venv, and once I |
Hi @webknjaz, |
@andresfrancopt the person commenting before you said it worked. |
There is actually a universal wheel available, but the dynamic libraries in the universal wheel are x86_64 only.
The So long as
|
This was the root cause of The network connection plugin checks for
|
Hi @ryanmerolle. Does the steps shared by @webknjaz or @samdoran their comment work for you? |
Sorry I missed this update. Here is the error I get on my m1 MacBook: $ pip install --no-binary :all: ansible-pylibssh
WARNING: Skipping /opt/homebrew/lib/python3.11/site-packages/cffi-1.16.0.dist-info due to invalid metadata entry 'name'
Collecting ansible-pylibssh
Downloading ansible-pylibssh-1.1.0.tar.gz (106 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 106.2/106.2 kB 4.0 MB/s eta 0:00:00
Installing build dependencies ... /
done
Getting requirements to build wheel ... done
Installing backend dependencies ... done
Preparing metadata (pyproject.toml) ... done
Building wheels for collected packages: ansible-pylibssh
Building wheel for ansible-pylibssh (pyproject.toml) ... error
error: subprocess-exited-with-error
× Building wheel for ansible-pylibssh (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [6 lines of output]
[1/1] Cythonizing /private/var/folders/ct/kd8qq0sd7y1218smxjw9fwsh0000gn/T/pip-install-gmxpv3cu/ansible-pylibssh_35f12a538de049858f6ca36822265f2e/src/pylibsshext/_libssh_version.pyx
/private/var/folders/ct/kd8qq0sd7y1218smxjw9fwsh0000gn/T/pip-install-gmxpv3cu/ansible-pylibssh_35f12a538de049858f6ca36822265f2e/src/pylibsshext/_libssh_version.c:1201:10: fatal error: 'libssh/libssh.h' file not found
#include "libssh/libssh.h"
^~~~~~~~~~~~~~~~~
1 error generated.
error: command '/usr/bin/clang' failed with exit code 1
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for ansible-pylibssh
Failed to build ansible-pylibssh |
That looks like you are missing the path to |
It all makes sense to me, just not super intuitive on the mac/arm space. If anyone stumbles on this, make sure to install libssh using brew if installing native to mac, or if using a linux container on mac install the relevant libssh-dev package. Feel free to close this. Thanks for your help! |
I'm labeling this as a "docs" issue since it seems to me that this information would be useful to be documented. Especially in the context of Python 3.12 which we don't currently ship wheels for. |
@webknjaz Cannot we really something to make this build out of the box? This bug is directly affecting devtools team and lightspeed work. Ideally shipping py312 arm64 wheel should even avoid the need to build it. |
There's no usable way of having runners for this. Maybe, it's possible to have universal2 macOS wheels but that would be something that's not even verified to function. I'll get back to this once I complete my other packaging related activities that may provide me with extra insights. |
- discover broken virtualens (after python upgrade) - implement workaround for building ansible-pylibssh Related: ansible/pylibssh#207
- discover broken virtualens (after python upgrade) - implement workaround for building ansible-pylibssh Related: ansible/pylibssh#207
* Improve test-setup.sh for macos - discover broken virtualens (after python upgrade) - implement workaround for building ansible-pylibssh Related: ansible/pylibssh#207 * Make dockerfile dependabot compatible See dependabot/dependabot-core#6067
just adding my experience with it here: The only way i could get it to work was locally building it as per https://stackoverflow.com/questions/74048675/cannot-install-ansible-pylibssh-on-macos Afterwards ansible picked it up just fine |
|
After checking multiple workarounds I find out - my ansible installed globally doesn't see any lib in venv like Святослав said
done. |
SUMMARY
add Package for macos arm64
ISSUE TYPE
ADDITIONAL INFORMATION
N/A
The text was updated successfully, but these errors were encountered: