These are chat archives for rust-lang/rust
hi, I'm cross compiling openssl for raspberry pi but ran into this error:
error: linking with `gcc-sysroot` failed: exit code: 1 note: /root/tools/pi-tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/../lib/gcc/arm-linux-gnueabihf/4.8.3/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lssl /root/tools/pi-tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/../lib/gcc/arm-linux-gnueabihf/4.8.3/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lcrypto
I have a feeling I need to link
crypto up somehow to the compiled openssl but I'm not entirely sure how. Can someone point me to the correct direction please? Thank you so much
libcrypto.soin your sysroot?
/opt/openssl/libwhere I download and compile from source, also tried to copy those files to
OPENSSL_DIR=/opt/openssl cargo build?
cargo build --targetcommand to use what I have cross-compiled
rootis usually not a good idea.
OPENSSL_DIR=/opt/openssl cargo buildas well, no luck. I'm using a docker container to build atm so kind of cheating and just use
rootfor the time being :p
CARGO_BUILD_RUSTFLAGS="-C link_args=-L/path/to/libs" cargo build --target ...
Updating registry 'https://github.com/rust-lang/crates.io-index'step :( will need to figure out why. @tanriol how do you put lib's files into sysroot? and where is sysroot?
arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/arm-linux-gnueabihf/libc/usr/include/openssl/, libraries (.a, .so and symlink) in