Code

rules, collection4.install: Use dh_install to install and move files.
[pkg-collection4.git] / debian / rules
1 #! /usr/bin/make -f
2 # debian/rules for collection4
3 #
4 # Written by Sebastian Harl <tokkee@debian.org>
6 include /usr/share/quilt/quilt.make
8 # Uncomment this to turn on verbose mode.
9 #export DH_VERBOSE=1
11 # These are used for cross-compiling and for saving the configure script
12 # from having to guess our platform (since we know it already)
13 DEB_HOST_GNU_TYPE   ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
14 DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
16 CFLAGS = -Wall -g
18 ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
19         CFLAGS += -O0
20 else
21         CFLAGS += -O2
22 endif
24 config.status: configure
25         dh_testdir
26         
27         ./configure \
28                         --host=$(DEB_HOST_GNU_TYPE) \
29                         --build=$(DEB_BUILD_GNU_TYPE) \
30                         --prefix=/usr \
31                         --sysconfdir=/etc \
32                         --mandir=\$${prefix}/share/man \
33                         CFLAGS="$(CFLAGS)"
35 build: build-stamp
37 build-stamp: $(QUILT_STAMPFN) config.status
38         dh_testdir
39         
40         $(MAKE)
41         
42         touch build-stamp
44 clean: unpatch
45         dh_testdir
46         dh_testroot
47         rm -f build-stamp
48         
49         [ ! -f Makefile ] || $(MAKE) distclean
50         
51         dh_clean
53 install: build
54         dh_testdir
55         dh_testroot
56         dh_prep
57         dh_installdirs
58         
59         $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
60         
61         dh_install --sourcedir=debian/tmp --fail-missing
63 binary-indep: build install
64         # nothing to do here
66 binary-arch: build install
67         dh_testdir
68         dh_testroot
69         dh_installchangelogs
70         dh_installdocs -a -A AUTHORS README
71         dh_link -a
72         dh_strip -a
73         dh_compress -a
74         dh_fixperms -a
75         dh_installdeb -a
76         dh_shlibdeps -a
77         dh_gencontrol -a
78         dh_md5sums -a
79         dh_builddeb -a
81 binary: binary-indep binary-arch
82 .PHONY: build clean binary-indep binary-arch binary install