From edaa56041ceb3185d9c104ca72c457a5e7ae6e03 Mon Sep 17 00:00:00 2001 From: Peter Simons Date: Mon, 16 Dec 2013 13:55:16 +0100 Subject: pkgs/build-support/cabal: configure a proper library rpath for dynamically linked executables --- pkgs/build-support/cabal/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'pkgs/build-support') diff --git a/pkgs/build-support/cabal/default.nix b/pkgs/build-support/cabal/default.nix index b17f720e56189..d99faf41f88d3 100644 --- a/pkgs/build-support/cabal/default.nix +++ b/pkgs/build-support/cabal/default.nix @@ -156,7 +156,7 @@ assert !enableStaticLibraries -> versionOlder "7.7" ghc.version; (optional (versionOlder "7" ghc.version) (enableFeature self.enableStaticLibraries "library-vanilla")) (optional (versionOlder "7.4" ghc.version) (enableFeature self.enableSharedExecutables "executable-dynamic")) (optional (versionOlder "7" ghc.version) (enableFeature self.doCheck "tests")) - ]; + ] ++ optional self.enableSharedExecutables "--ghc-option=-optl=-Wl,-rpath=$ORIGIN/../lib/${ghc.ghc.name}/${self.pname}-${self.version}"; # GHC needs the locale configured during the Haddock phase. LANG = "en_US.UTF-8"; -- cgit 1.4.1