File: rules

package info (click to toggle)
hscolour 1.25-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 224 kB
  • sloc: haskell: 1,171; sh: 15; makefile: 8
file content (26 lines) | stat: -rwxr-xr-x 950 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/usr/bin/make -f

# 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.
export 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.
execute_before_dh_auto_configure: hscolour-wrapper

%:
	dh $@