9 HADDOCK=../inplace/bin/haddock
10 HADDOCK_FILES=`ls -1 */dist-install/doc/html/*/*.haddock | sort`
13 DPH_HADDOCK_FILES=`ls -1 dph/*/dist-install/doc/html/*/*.haddock | sort`
14 HADDOCK_FILES="$HADDOCK_FILES $DPH_HADDOCK_FILES"
16 for HADDOCK_FILE in $HADDOCK_FILES
18 LIBPATH=`echo "$HADDOCK_FILE" | sed 's#/dist-install.*##'`
19 NAME=`echo "$HADDOCK_FILE" | sed 's#.*/##' | sed 's#\.haddock$##'`
20 # It's easier to portably remove tabs with tr than to try to get
21 # sed to do what we want
22 VERSION=`grep -i '^version:' $LIBPATH/$NAME.cabal | sed 's/.*://' | tr -d ' \t'`
23 HADDOCK_ARG="--read-interface=${NAME}-${VERSION},$HADDOCK_FILE"
24 HADDOCK_ARGS="$HADDOCK_ARGS $HADDOCK_ARG"
28 HADDOCK=../../../../../bin/haddock
29 # We don't want the GHC API to swamp the index
30 HADDOCK_FILES=`ls -1 */*.haddock | grep -v '/ghc\.haddock' | sort`
31 for HADDOCK_FILE in $HADDOCK_FILES
33 NAME_VERSION=`echo "$HADDOCK_FILE" | sed 's#/.*##'`
34 HADDOCK_ARG="--read-interface=${NAME_VERSION},$HADDOCK_FILE"
35 HADDOCK_ARGS="$HADDOCK_ARGS $HADDOCK_ARG"
40 # Now create the combined contents and index pages
41 $HADDOCK --gen-index --gen-contents -o . \
42 -t "Haskell Hierarchical Libraries" \
46 # Unhandled Windows help stuff?:
48 #libraries.HxS : libraries.txt
52 # ( cd $(HTML_DIR) && if Hxcomp -p libraries.HxC -o ../$@ ; then false ; else true ; fi ) || true
54 #libraries.chm : libraries.txt
57 # --html-help=mshelp \
58 # ( cd $(HTML_DIR) && if hhc libraries.hhp ; then false ; else true ; fi && mv libraries.chm .. ) || true