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

Won't compile on aarch64 because of cargon crate. #11

Closed
bentwire opened this issue Feb 27, 2019 · 2 comments
Closed

Won't compile on aarch64 because of cargon crate. #11

bentwire opened this issue Feb 27, 2019 · 2 comments

Comments

@bentwire
Copy link

Love this library, does exactly what I need. However I am now porting my app to aarch64 and I can't get the library to compile. I tried disabling cargon by using the below dependency config but it still tries to compile cargon:

[dependencies.djangohashers]
version = "1.0.1"
features = ["fpbkdf2"]

Here is the cargon error:

running: "cc" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-g" "-I" "phc-winner-argon2/include" "-march=native" "-Wall" "-Wextra" "-o" "/home/android/galileo-client/target/release/build/cargon-77514a8c699451ee/out/phc-winner-argon2/src/opt.o" "-c" "phc-winner-argon2/src/opt.c"
cargo:warning=In file included from phc-winner-argon2/src/opt.c:19:0:
cargo:warning=phc-winner-argon2/src/opt.h:18:10: fatal error: emmintrin.h: No such file or directory
cargo:warning= #include <emmintrin.h>
cargo:warning=          ^~~~~~~~~~~~~
cargo:warning=compilation terminated.
exit code: 1

Looks like it is trying to compile optimizations that don't apply for ARM?

Is there any quick fix I can do to make my app compile?

Thanks,
Mike

@bentwire
Copy link
Author

Looks like I just needed to add "default-features = false" to my deps section for djangohashers.

@Racum
Copy link
Owner

Racum commented Jun 21, 2020

If you want to try with all features now, I changed the Argon2 dependency to another one in pure-Rust, that compiles nicely on ARM.

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

No branches or pull requests

2 participants