Skip to content

Commit

Permalink
nix: Fix execution errors regarding runtime C lib.
Browse files Browse the repository at this point in the history
  • Loading branch information
archseer committed Jan 19, 2021
1 parent 22fe2eb commit 240f3a6
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions shell.nix
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
{ pkgs ? import <nixpkgs> {} }:
{ stdenv, pkgs ? import <nixpkgs> {} }:

pkgs.mkShell {
nativeBuildInputs = with pkgs; [
(rust-bin.nightly.latest.rust.override { extensions = ["rust-src"]; })
lld_10
# pkgconfig
stdenv.cc.cc.lib
# pkg-config
];
RUSTFLAGS = "-C link-arg=-fuse-ld=lld -C target-cpu=native";
RUST_BACKTRACE = "1";
# https://github.com/rust-lang/rust/issues/55979
LD_LIBRARY_PATH="${stdenv.cc.cc.lib}/lib64:$LD_LIBRARY_PATH";
}

0 comments on commit 240f3a6

Please # to comment.