Imported Debian patch 2.1-1
[debian/cpmtools] / debian / rules
1 #!/usr/bin/make -f
2
3 # Uncomment this to turn on verbose mode.
4 #export DH_VERBOSE=1
5
6 # This is the debhelper compatability version to use.
7 export DH_COMPAT=3
8
9 configure: configure-stamp
10 configure-stamp:
11         dh_testdir
12         ./configure --prefix=/usr --mandir=\$${prefix}/share/man \
13                 --datadir=/etc/cpmtools
14         touch configure-stamp
15
16 build: build-stamp
17
18 build-stamp: configure-stamp 
19         dh_testdir
20         $(MAKE)
21         touch build-stamp
22
23 clean:
24         dh_testdir
25         dh_testroot
26         rm -f build-stamp configure-stamp
27         -$(MAKE) distclean
28
29         -test -r /usr/share/misc/config.sub && \
30                 cp -f /usr/share/misc/config.sub config/config.sub
31         -test -r /usr/share/misc/config.guess && \
32                 cp -f /usr/share/misc/config.guess config/config.guess
33
34         dh_clean
35
36 install: build
37         dh_testdir
38         dh_testroot
39         dh_clean -k
40         dh_installdirs
41         $(MAKE) install prefix=$(CURDIR)/debian/cpmtools/usr 
42
43 # Build architecture-independent files here.
44 binary-indep: build install
45
46 # Build architecture-dependent files here.
47 binary-arch: build install
48         dh_testdir
49         dh_testroot
50         dh_installdocs
51         dh_installexamples
52         dh_installmenu
53         dh_installcron
54         dh_installman
55         dh_installinfo
56         dh_installchangelogs 
57         dh_link
58         dh_strip
59         dh_compress
60         dh_fixperms
61         dh_installdeb
62         dh_shlibdeps
63         dh_gencontrol
64         dh_md5sums
65         dh_builddeb
66
67 binary: binary-indep binary-arch
68 .PHONY: build clean binary-indep binary-arch binary install configure