backout of commit e212e10dee

Summary: mold apparently breaks linking to several external libraries, meaning
that the `jj` binary is useless as it can't load e.g. `libgit2.so` -- but
somehow I didn't catch it. Backout until a solution can be pinpointed. We can at
least give off a sigh of relief knowing that our link times aren't too bad yet.

Signed-off-by: Austin Seipp <aseipp@pobox.com>
Change-Id: I6e1851c339ddc72d32c201a44a7ddc49
This commit is contained in:
Austin Seipp 2023-08-04 17:23:35 -05:00
parent 4a10ea4e3e
commit 688029428b

View file

@ -42,10 +42,6 @@
cargo = rust-version;
};
# NOTE (aseipp): on Linux, go ahead and use mold by default to improve
# link times a bit; mostly useful for debug build speed, but will help
# over time if we ever get more dependencies, too
useMoldLinker = pkgs.stdenv.isLinux;
in
{
packages = {
@ -132,16 +128,12 @@
cargo-insta
cargo-nextest
cargo-watch
# Extra, more specific tools follow
] ++ pkgs.lib.optionals useMoldLinker [ mold ];
];
shellHook = ''
export RUST_BACKTRACE=1
export ZSTD_SYS_USE_PKG_CONFIG=1
export LIBSSH2_SYS_USE_PKG_CONFIG=1
'' + pkgs.lib.optionalString useMoldLinker ''
export RUSTFLAGS="-C link-arg=-fuse-ld=mold $RUSTFLAGS"
'';
};
}));