- Fixed --config
[tinc] / debian / rules
1 #!/usr/bin/make -f
2 # Sample debian/rules that uses debhelper.
3 # GNU copyright 1997 to 1999 by Joey Hess.
4
5 # Uncomment this to turn on verbose mode.
6 #export DH_VERBOSE=1
7
8 # This is the debhelper compatability version to use.
9 export DH_COMPAT=1
10
11 build: build-stamp
12 build-stamp:
13         dh_testdir
14
15 #       # If the Makefile.in.in file in po/ already contains DESTDIR support, skip the patching.
16         cd `pwd`/po ; ( \
17           if ! grep DESTDIR Makefile.in.in > /dev/null ; then \
18             patch -Ns -p0 < `pwd`/../debian/po-Makefile.in.in.diff || true ;\
19           fi ;\
20         )
21         ./configure --prefix=/usr --mandir=\$${prefix}/share/man --infodir=\$${prefix}/share/info --sysconfdir=/etc
22         $(MAKE)
23
24         touch build-stamp
25
26 clean:
27         dh_testdir
28         dh_testroot
29         rm -f build-stamp
30
31         -$(MAKE) distclean
32
33         dh_clean
34
35 install: build
36         dh_testdir
37         dh_testroot
38         dh_clean -k
39         dh_installdirs
40
41         $(MAKE) install DESTDIR=`pwd`/debian/tmp
42         mkdir -p `pwd`/debian/tmp/etc/tinc/example
43         cp doc/tinc.conf.sample `pwd`/debian/tmp/etc/tinc/example/tinc.conf
44         ln -s /usr/share/doc/tinc/README.Debian `pwd`/debian/tmp/etc/tinc/example/README
45
46
47 # Build architecture-independent files here.
48 binary-indep: build install
49 # We have nothing to do by default.
50
51 # Build architecture-dependent files here.
52 binary-arch: build install
53         dh_testdir
54         dh_testroot
55         dh_installdocs
56         dh_installexamples
57         dh_installinit
58         dh_installmanpages
59         dh_installinfo
60         dh_installchangelogs ChangeLog
61         dh_link
62         dh_strip
63         dh_compress
64         dh_fixperms
65         dh_installdeb
66         dh_perl
67         dh_shlibdeps
68         dh_gencontrol
69         dh_md5sums
70         dh_builddeb
71
72 binary: binary-indep binary-arch
73 .PHONY: build clean binary-indep binary-arch binary install