haskell/with-packages-wrapper.nix: install "doc" outputs

We were previously just installing the "out" output which broke when
we recently changed to generating multiple outputs.

Fixes #76837
This commit is contained in:
Matthew Bauer 2020-01-02 16:05:45 -05:00
parent a77a2cfe4a
commit e915608618

View File

@ -1,4 +1,4 @@
{ lib, stdenv, ghc, llvmPackages, packages, symlinkJoin, makeWrapper { lib, stdenv, ghc, llvmPackages, packages, buildEnv, makeWrapper
, withLLVM ? false , withLLVM ? false
, postBuild ? "" , postBuild ? ""
, ghcLibdir ? null # only used by ghcjs, when resolving plugins , ghcLibdir ? null # only used by ghcjs, when resolving plugins
@ -51,12 +51,13 @@ let
++ lib.optional stdenv.targetPlatform.isDarwin llvmPackages.clang); ++ lib.optional stdenv.targetPlatform.isDarwin llvmPackages.clang);
in in
if paths == [] && !withLLVM then ghc else if paths == [] && !withLLVM then ghc else
symlinkJoin { buildEnv {
# this makes computing paths from the name attribute impossible; # this makes computing paths from the name attribute impossible;
# if such a feature is needed, the real compiler name should be saved # if such a feature is needed, the real compiler name should be saved
# as a dedicated drv attribute, like `compiler-name` # as a dedicated drv attribute, like `compiler-name`
name = ghc.name + "-with-packages"; name = ghc.name + "-with-packages";
paths = paths ++ [ghc]; paths = paths ++ [ghc];
extraOutputsToInstall = ["doc"];
postBuild = '' postBuild = ''
. ${makeWrapper}/nix-support/setup-hook . ${makeWrapper}/nix-support/setup-hook