From df241fd6edf486675008e9b2d22206319a7674d4 Mon Sep 17 00:00:00 2001
From: Eelco Dolstra <eelco.dolstra@logicblox.com>
Date: Wed, 4 Jun 2008 09:11:47 +0000
Subject: [PATCH] * Don't include /var/run/current-system/sw/lib in the
 LD_LIBRARY_PATH   by default since this can really make the functioning of  
 applications unpredictable as they can pick up arbitrary   library versions
 from that directory.  LD_LIBRARY_PATH should only   contain very specific
 paths (like /var/run/opengl-driver/lib for   overriding the system OpenGL
 implementation, or the NSS module   path).  This is even more important given
 that the stdenv-updates   branch uses RUNPATHs instead of RPATHs, so *all*
 libraries are   overridable by LD_LIBRARY_PATH.

svn path=/nixos/trunk/; revision=11967
---
 etc/profile.sh | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/etc/profile.sh b/etc/profile.sh
index 3696012f61b..d03a4dd4e49 100644
--- a/etc/profile.sh
+++ b/etc/profile.sh
@@ -1,7 +1,7 @@
 export PATH=@wrapperDir@:/var/run/current-system/sw/bin:/var/run/current-system/sw/sbin
-export LD_LIBRARY_PATH=/var/run/current-system/sw/lib
+export LD_LIBRARY_PATH=/var/run/opengl-driver/lib
 if test -n "@nssModulesPath@"; then
-    LD_LIBRARY_PATH=@nssModulesPath@:$LD_LIBRARY_PATH
+    LD_LIBRARY_PATH=@nssModulesPath@$:$LD_LIBRARY_PATH
 fi
 export MODULE_DIR=@modulesTree@/lib/modules
 export NIXPKGS_CONFIG=/nix/etc/config.nix