mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-20 12:42:24 +00:00
Use the same directory layout for user-installed Haskell libraries that GHC
uses for its core libraries, so that these files integrate seamlessly into one profile, living right next to each other. This change is eventually going to simply our with-packages wrapper quite a bit.
This commit is contained in:
parent
3e1de0f4e8
commit
d09269a22e
|
@ -121,7 +121,7 @@
|
|||
done
|
||||
|
||||
echo "configure flags: $extraConfigureFlags $configureFlags"
|
||||
./Setup configure --verbose --prefix="$out" $extraConfigureFlags $configureFlags
|
||||
./Setup configure --verbose --prefix="$out" --libdir='$prefix/lib/$compiler' --libsubdir='$pkgid' $extraConfigureFlags $configureFlags
|
||||
|
||||
eval "$postConfigure"
|
||||
'';
|
||||
|
@ -156,7 +156,7 @@
|
|||
|
||||
ensureDir $out/bin # necessary to get it added to PATH
|
||||
|
||||
local confDir=$out/lib/ghc-pkgs/ghc-${ghc.ghc.version}
|
||||
local confDir=$out/lib/ghc-${ghc.ghc.version}/package.conf.d
|
||||
local installedPkgConf=$confDir/${self.fname}.installedconf
|
||||
local pkgConf=$confDir/${self.fname}.conf
|
||||
ensureDir $confDir
|
||||
|
|
|
@ -12,7 +12,7 @@ fi
|
|||
PATH="$2:$PATH"
|
||||
IFS=":"
|
||||
for p in $PATH; do
|
||||
PkgDir="$p/../lib/ghc-pkgs/ghc-$version"
|
||||
PkgDir="$p/../lib/ghc-$version/package.conf.d"
|
||||
for i in $PkgDir/*.installedconf; do
|
||||
# output takes place here
|
||||
test -f $i && echo -n " $prefix$i"
|
||||
|
|
|
@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
|
|||
echo "Linking selected packages and dependencies:"
|
||||
|
||||
for currentPath in ${stdenv.lib.concatStringsSep " " allPackages}; do
|
||||
currentPkgDir="$currentPath/lib/ghc-pkgs/ghc-${ghc.version}"
|
||||
currentPkgDir="$currentPath/lib/ghc-${ghc.version}/package.conf.d/"
|
||||
# Check if current path is a Cabal package for the current GHC
|
||||
if test -d $currentPkgDir; then
|
||||
echo -n "Linking $currentPath "
|
||||
|
|
Loading…
Reference in a new issue