debian swirl logo

Back to the packages list hscolour

#!/usr/bin/make -f

# Standard way of building Haskell binary.
include /usr/share/cdbs/1/rules/debhelper.mk
include /usr/share/cdbs/1/class/hlibrary.mk

# In order to generated colourised HTML for the libghc-hscolour-doc package
# we need a special hack because the colour docs are generated by an executable
# create by this package and we don't want this package to depend on itself.

pwd := $(shell pwd)

# Modify the GHC configure parameters to point to a local version of
# HsColour.
DEB_SETUP_GHC_CONFIGURE_ARGS += --with-hscolour=$(pwd)/hscolour-wrapper

# Generate a fake version of the executable (a trivial shell script) which is
# available at configure time. This shell script will exec the real HsColour
# executable if it can be found. If it can't be found it will give a sensible
# result for a version request (which is enough to fool haddock) and exit with
# an error for anything else.
hscolour-wrapper : debian/hscolour-wrapper
		cp $+ $@
		chmod u+x $@

# Force generation of the wrapper script.
dist-ghc : hscolour-wrapper

clean ::
		rm -f hscolour-wrapper

Builds:

hscolour
haskell program to colourise haskell code
libghc-hscolour-dev
ghc libraries for colourising haskell code${haskell:shortblurb}
libghc-hscolour-doc
documentation for libghc-hscolour-dev${haskell:shortblurb}
libghc-hscolour-prof
profiling libraries for colourising haskell code${haskell:shortblurb}