Currently the libsodium crate isn't building because there's a hash mismatch on the file its downloading. On its own that's a little concerning but it should be possible to provide a libsodium another way.
The following Nix shell hook should be enough to instruct libsodium-sys-stable to link against the libsodium that I'm providing
Caused by:
process didn't exit successfully: `/home/thetasinner/source/projectname/target/debug/build/lair_keystore-523f875434d8fda4/build-script-build` (exit status: 127)
--- stderr
/home/thetasinner/source/projectname/target/debug/build/lair_keystore-523f875434d8fda4/build-script-build: error while loading shared libraries: libsodium.so.26: cannot open shared object file: No such file or directory
warning: build failed, waiting for other jobs to finish...
That means the build.rs for lair_keystore can't be compiled because it can't find the libsodium I'm asking it to link with. I don't fully get why but I'm assuming the build process for build scripts differs in some way to the way Cargo builds crates. Just depending on lair_keystore_api in my project works fine, but as soon as lair_keystore is pulled in it breaks... so I'm fairly sure I've configured everything right.
The only workaround for this I can find is to set export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$SODIUM_LIB_DIR. That does work but it's requiring me to set something that is linker specific, outside the Cargo build process which is more likely to break than I'd like.
Is there any way the build dependency on lair_keystore_api from lair_keystore can be dropped to make this build configuration simpler?
Currently the libsodium crate isn't building because there's a hash mismatch on the file its downloading. On its own that's a little concerning but it should be possible to provide a libsodium another way.
The following Nix shell hook should be enough to instruct
libsodium-sys-stable
to link against the libsodium that I'm providingUnfortunately, this fails with:
That means the
build.rs
forlair_keystore
can't be compiled because it can't find the libsodium I'm asking it to link with. I don't fully get why but I'm assuming the build process for build scripts differs in some way to the way Cargo builds crates. Just depending onlair_keystore_api
in my project works fine, but as soon aslair_keystore
is pulled in it breaks... so I'm fairly sure I've configured everything right.The only workaround for this I can find is to set
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$SODIUM_LIB_DIR
. That does work but it's requiring me to set something that is linker specific, outside the Cargo build process which is more likely to break than I'd like.Is there any way the build dependency on
lair_keystore_api
fromlair_keystore
can be dropped to make this build configuration simpler?