Skip to content

Commit 96a471b

Browse files
committed
Fix direnv error when LD_LIBRARY_PATH is initially unset
1 parent 236a6eb commit 96a471b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ghc.nix

+1-1
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ hspkgs.shellFor rec {
247247
248248
# "nix-shell --pure" resets LANG to POSIX, this breaks "make TAGS".
249249
export LANG="en_US.UTF-8"
250-
export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:${lib.makeLibraryPath depsSystem}"
250+
export LD_LIBRARY_PATH="''${LD_LIBRARY_PATH:+''${LD_LIBRARY_PATH}:}${lib.makeLibraryPath depsSystem}"
251251
unset LD
252252
253253
${lib.optionalString withDocs "export FONTCONFIG_FILE=${fonts}"}

0 commit comments

Comments
 (0)