haskell: add doc outputs to with-packages-wrapper.nix
We want to have all doc outputs as well (also e.g. ghc documentation). Adds a bit of documentation to the postInstall script.
This commit is contained in:
parent
f9a9ea920a
commit
546d0c0460
@ -52,10 +52,12 @@ buildEnv {
|
||||
# as a dedicated drv attribute, like `compiler-name`
|
||||
name = ghc.name + "-with-packages";
|
||||
paths = paths ++ [ghc];
|
||||
extraOutputsToInstall = [ "out" "doc" ];
|
||||
inherit ignoreCollisions;
|
||||
postBuild = ''
|
||||
. ${makeWrapper}/nix-support/setup-hook
|
||||
|
||||
# Work around buildEnv sometimes deciding to make bin a symlink
|
||||
if test -L "$out/bin"; then
|
||||
binTarget="$(readlink -f "$out/bin")"
|
||||
rm "$out/bin"
|
||||
@ -63,6 +65,8 @@ buildEnv {
|
||||
chmod u+w "$out/bin"
|
||||
fi
|
||||
|
||||
# wrap compiler executables with correct env variables
|
||||
|
||||
for prg in ${ghcCommand} ${ghcCommand}i ${ghcCommand}-${ghc.version} ${ghcCommand}i-${ghc.version}; do
|
||||
if [[ -x "${ghc}/bin/$prg" ]]; then
|
||||
rm -f $out/bin/$prg
|
||||
|
Loading…
Reference in New Issue
Block a user