-
Notifications
You must be signed in to change notification settings - Fork 673
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
fix Mac install as clang no longer has that option #345
Conversation
Hi @srajabi, can you please provide more details? |
@yurymalkov I suspect it's M1. |
Yeah, it seems to be M1 specific (https://stackoverflow.com/questions/65966969/why-does-march-native-not-work-on-apple-m1 ) |
Though it have been fixed for cmake only and it still omits march native for intel mac builds. |
Looks like I'm a bit ahead of you for clang version though:
This issue would persistently present itself for a few days, but now I can't reproduce it at all. I'm not on an M1 mac, and I don't think @MiloTodt is either given the screenshot. Edit: trying to sort out if there's some caching going on with pip since installing it correctly from my branch |
Oh, got it. I was inattentive. Can this be a bug in clang? |
You might be able to help me here, I'm not sure why but it's no longer executing the BuildExt function. I've modified it to be something erroneous just for a sanity check. My build now never includes the --march=native, I'm on master:
Could be a bug in Clang, the above behaviour probably makes it super hard to track this down. |
It seems pip will continue to use the cached shared object file stubbornly despite my best efforts, tried:
Only thing that consistently seems to force recompilation with the But I can see the Declining the PR as it doesn't seem to be an hnswlib issue but perhaps a clang bug. |
I see. Thanks for looking into it! |
The following error occurs when trying to
pip install hnswlib
:clang: error: the clang compiler does not support '-march=native'
The command:
clang -cc1 --help | grep march
Returns nothing.
Mac no longer has "-march=native" option.
This PR modifies setup.py to not include that option for mac.