~ubuntu-branches/debian/lenny/haskell-utils/lenny

« back to all changes in this revision

Viewing changes to scripts/4/rules

  • Committer: Bazaar Package Importer
  • Author(s): Ian Lynagh (wibble)
  • Date: 2008-02-21 02:30:03 UTC
  • mfrom: (2.1.8 hardy)
  • Revision ID: james.westby@ubuntu.com-20080221023003-x73ww9m1rjpbiewh
Tags: 1.11
* We now make tight (build-)deps for the Cabal packages we depend on.
  This means that we can't have problems caused by cross-module
  inlining, or even Cabal version numbers becoming mismatched.
  Closes: #432799.
* Ignore dotfiles in varfile directories.
  In particular, this means that we ignore things like vim swapfiles.
  Closes: #445627.
* Fix the doc directory used in libghc6-PACKAGE-doc.postrm.
  Closes: #463998.
* Move the ghc6 version dependency logic into this package, and
  ignore what the ghc6 package tells us. This allows us to vary it,
  in particular make changes to the supported arches list, without
  having to do another ghc6 build on all platforms.
* All platforms now support ghc6, so make library build-deps just
      ghc6 (>= 6.8.2),                ghc6 (<< 6.8.2+)
  rather than
      ghc6 (>= 6.8.2) [$ghc6_arches], ghc6 (<< 6.8.2+) [$ghc6_arches]
* Changes in Debian packaging scripts 10 over 9:
  * We now use ${impl:ghc6:lib_build_deps} rather than ${ghc6_lib_bdeps}.
    Closes: #460077.
  * We now use ${impl:ghc6:*_deps} rather than ${ghc6_*_deps} and
    hardcoded, unversioned deps.
  * Call canonicalise-comma-list on the depends and suggests fields in
    control.in. This works around bugs in lintian, where it gets
    confused and starts giving spurious warnings.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/usr/bin/make -f
 
2
# Generic Haskell cabal library debian/rules v0.4 by Ian Lynagh,
 
3
# based on the example by Joey Hess.
 
4
# This file is public domain software.
 
5
 
 
6
# Uncomment this to turn on verbose mode.
 
7
#export DH_VERBOSE=1
 
8
 
 
9
CONFIGURE_OPTS = --enable-library-vanilla \
 
10
                 --enable-library-profiling \
 
11
                 --enable-library-for-ghci \
 
12
                 --enable-split-objs
 
13
 
 
14
build: build-stamp
 
15
build-stamp:
 
16
        dh_testdir
 
17
 
 
18
        update-haskell-control --check
 
19
        ghc --make Setup.hs -o setup-ghc
 
20
        ./setup-ghc configure --ghc --prefix=/usr $(CONFIGURE_OPTS)
 
21
        ./setup-ghc build
 
22
 
 
23
        touch build-stamp
 
24
 
 
25
clean:
 
26
        dh_testdir
 
27
        dh_testroot
 
28
        rm -f build-stamp
 
29
 
 
30
        -./setup-ghc clean
 
31
        rm -f Setup.o Setup.hi setup-ghc
 
32
 
 
33
        dh_clean
 
34
 
 
35
install: build
 
36
        dh_testdir
 
37
        dh_testroot
 
38
        dh_clean -k
 
39
        dh_installdirs
 
40
 
 
41
        ./setup-ghc copy --copy-prefix=`pwd`/debian/`dh_listpackages`/usr
 
42
        ./setup-ghc register --gen-script
 
43
        ./setup-ghc unregister --gen-script
 
44
        mkdir -p `pwd`/debian/`dh_listpackages`/usr/lib/`dh_listpackages`
 
45
        mv register.sh `pwd`/debian/`dh_listpackages`/usr/lib/`dh_listpackages`
 
46
        mv unregister.sh `pwd`/debian/`dh_listpackages`/usr/lib/`dh_listpackages`
 
47
 
 
48
update-generated-files:
 
49
        update-haskell-control
 
50
        sed "s/@PACKAGE@/`dh_listpackages`/g" \
 
51
                      debian/`dh_listpackages`.prerm.in \
 
52
                    > debian/`dh_listpackages`.prerm
 
53
        sed "s/@PACKAGE@/`dh_listpackages`/g" \
 
54
                      debian/`dh_listpackages`.postinst.in \
 
55
                    > debian/`dh_listpackages`.postinst
 
56
 
 
57
# Build architecture-independent files here.
 
58
binary-indep: build install
 
59
# We have nothing to do by default.
 
60
 
 
61
# Build architecture-dependent files here.
 
62
binary-arch: build install
 
63
        dh_testdir
 
64
        dh_testroot
 
65
        dh_installchangelogs
 
66
        dh_installdocs
 
67
        dh_installexamples
 
68
#       dh_install
 
69
#       dh_installmenu
 
70
#       dh_installdebconf       
 
71
#       dh_installlogrotate
 
72
#       dh_installemacsen
 
73
#       dh_installcatalogs
 
74
#       dh_installpam
 
75
#       dh_installmime
 
76
#       dh_installinit
 
77
#       dh_installcron
 
78
#       dh_installinfo
 
79
#       dh_undocumented
 
80
        dh_installman
 
81
        dh_link
 
82
        dh_strip
 
83
        dh_compress
 
84
        dh_fixperms
 
85
#       dh_perl
 
86
#       dh_python
 
87
#       dh_makeshlibs
 
88
        dh_installdeb
 
89
        dh_shlibdeps
 
90
        dh_gencontrol
 
91
        dh_md5sums
 
92
        dh_builddeb
 
93
 
 
94
binary: binary-indep binary-arch
 
95
.PHONY: build clean binary-indep binary-arch binary install