@@ -208,11 +208,18 @@ stdenv.mkDerivation ({
208 docdir="${docdir "$doc"}"
208 docdir="${docdir "$doc"}"
209 mkdir -p "$docdir"
209 mkdir -p "$docdir"
211+ # We accept that this might not produce any
212+ # output (hence the || true). Depending of
213+ # configuration flags, there might just be no
214+ # modules to run haddock on. E.g. a package
215+ # might turn into an empty one (see the fail
211 $SETUP_HS haddock \
217 $SETUP_HS haddock \
212 "--html" \
218 "--html" \
213 ${lib.optionalString doHoogle "--hoogle"} \
219 ${lib.optionalString doHoogle "--hoogle"} \
214 ${lib.optionalString hyperlinkSource "--hyperlink-source"} \
220 ${lib.optionalString hyperlinkSource "--hyperlink-source"} \
215− ${lib.concatStringsSep " " (component.setupHaddockFlags ++ setupGhcOptions)}
221+ ${lib.concatStringsSep " " (component.setupHaddockFlags ++ setupGhcOptions)} \
217 html="dist/doc/html/${componentId.cname}"
224 html="dist/doc/html/${componentId.cname}"