Added an example to test the WATC module. It lets you query whatsafterthecredits...
[maevies] / debian / rules
1 #!/usr/bin/make -f
2 # -*- makefile -*-
3 # Sample debian/rules that uses debhelper.
4 # GNU copyright 1997 to 1999 by Joey Hess.
5
6 # Uncomment this to turn on verbose mode.
7 #export DH_VERBOSE=1
8
9
10 # These are used for cross-compiling and for saving the configure script
11 # from having to guess our platform (since we know it already)
12 DEB_HOST_GNU_TYPE   ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
13 DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
14
15
16 CFLAGS = -Wall -g
17 PACKAGENAME = maevies
18
19 ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
20         CFLAGS += -O0
21 else
22         CFLAGS += -O2
23 endif
24 ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
25         INSTALL_PROGRAM += -s
26 endif
27
28 configure: configure-stamp
29 configure-stamp:
30         test -e ./configure || ./autogen.sh 
31         dh_testdir
32         # Add here commands to configure the package.
33         CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" ./configure --prefix=/usr
34         touch configure-stamp
35
36 build: build-stamp
37
38 build-stamp:  configure-stamp
39         dh_testdir
40
41         # Add here commands to compile the package.
42         $(MAKE)
43         touch build-stamp
44
45 clean:
46         dh_testdir
47         dh_testroot
48         rm -f build-stamp configure-stamp 
49
50         # Add here commands to clean up after the build process.
51         mv debian/rules debian/rules.save
52         -$(MAKE) distclean
53         mv debian/rules.save debian/rules
54
55         dh_clean
56
57 install: build
58         dh_testdir
59         dh_testroot
60         dh_clean -k
61         dh_installdirs
62
63     # Add here commands to install the package into debian/$(PACKAGENAME)
64         $(MAKE) DESTDIR=$(CURDIR)/debian/$(PACKAGENAME) install
65     
66
67 # Build architecture-independent files here.
68 binary-indep: build install
69 # We have nothing to do by default.
70
71 # Build architecture-dependent files here.
72 binary-arch: build install
73         dh_testdir
74         dh_testroot
75         dh_link
76         dh_strip
77         dh_compress
78         dh_fixperms
79         dh_installdeb
80         dh_shlibdeps
81         dh_gencontrol
82         dh_md5sums
83         dh_builddeb
84
85 binary: binary-indep binary-arch
86 .PHONY: build clean binary-indep binary-arch binary install