!FBuJyWXTGcGtHTPphC:nixos.org

Nix Rust

710 Members
Rust158 Servers

You have reached the beginning of time (for this room).


SenderMessageTime
12 Nov 2025
@inayet:matrix.orgInayet changed their display name from inayet to Inayet.12:37:29
@crop_tech:matrix.orgcrop i am trying to use this crate in a project that i work on on a nixos machine: https://github.com/HadrienG2/hwlocality
it depends on a c library that i add to the shell.nix in the buildInputs = with pkgs; [hwloc] and then set the libpath with libPath = with pkgs; lib.makeLibraryPath buildInputs; ... the library is loaded dynamically as the error appears only when i try to use the crate in rust.
the error is target/release/multi_thread: error while loading shared libraries: libhwloc.so.15: cannot open shared object file: No such file or directory
any suggestions how to fix this?
22:59:37
@crop_tech:matrix.orgcrop i now added the following line to the shell.nix
LD_LIBRARY_PATH = "${pkgs.lib.makeLibraryPath buildInputs}";
but i thought this is not recommended.
23:25:43
@crop_tech:matrix.orgcrop its not "recommended" because now i am missing other libraries (pipewire-...-jack-lib) ... and i don't know how it got put into the LDLIBRARYPATH variable automatically 23:33:14

Show newer messages


Back to Room ListRoom Version: 6