bb8c0b77 |
1 | #!/usr/bin/make -f |
2 | # -*- makefile -*- |
bb8c0b77 |
3 | |
4 | CFLAGS = -Wall -g |
bb8c0b77 |
5 | ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) |
6 | CFLAGS += -O0 |
7 | else |
8 | CFLAGS += -O2 |
9 | endif |
10 | |
ebb1f61c |
11 | build-apache13: |
bb8c0b77 |
12 | dh_testdir |
bb8c0b77 |
13 | chmod +x regen.sh |
14 | ./regen.sh |
ebb1f61c |
15 | make clean |
16 | ./configure \ |
17 | --with-afs-libs=/usr/lib/afs \ |
18 | --with-afs-headers=/usr/include/afs \ |
19 | --with-apxs=/usr/bin/apxs |
bb8c0b77 |
20 | $(MAKE) |
bb8c0b77 |
21 | |
ebb1f61c |
22 | build-apache20: |
bb8c0b77 |
23 | dh_testdir |
ebb1f61c |
24 | chmod +x regen.sh |
25 | ./regen.sh |
26 | make clean |
27 | ./configure \ |
28 | --with-afs-libs=/usr/lib/afs \ |
29 | --with-afs-headers=/usr/include/afs \ |
30 | --with-apache-headers=/usr/include/apache2 \ |
31 | --with-apxs=/usr/bin/apxs2 |
32 | $(MAKE) |
33 | mv .libs/mod_waklog.so .; true |
bb8c0b77 |
34 | |
ebb1f61c |
35 | apache13: build-apache13 |
bb8c0b77 |
36 | dh_testdir |
37 | dh_testroot |
38 | dh_clean -k --exclude ./_darcs/current/Makefile.orig --exclude ./Makefile.orig |
39 | dh_installdirs |
bb8c0b77 |
40 | mkdir -p debian/libapache-mod-waklog/usr/lib/apache/1.3/ |
41 | mkdir -p debian/libapache-mod-waklog/etc/apache/conf.d/ |
42 | cp mod_waklog.so debian/libapache-mod-waklog/usr/lib/apache/1.3/ |
43 | cp debian/waklog.load debian/libapache-mod-waklog/etc/apache/conf.d/waklog.conf |
44 | |
ebb1f61c |
45 | apache20: build-apache20 |
46 | dh_testdir |
47 | dh_testroot |
48 | dh_clean -k --exclude ./_darcs/current/Makefile.orig --exclude ./Makefile.orig |
49 | dh_installdirs |
50 | mkdir -p debian/libapache2-mod-waklog/usr/lib/apache2/modules/ |
51 | mkdir -p debian/libapache2-mod-waklog/etc/apache2/mods-available |
52 | cp mod_waklog.so debian/libapache2-mod-waklog/usr/lib/apache2/modules/ |
53 | cp debian/waklog.load debian/libapache2-mod-waklog/etc/apache2/mods-available |
54 | |
55 | clean: |
56 | dh_testdir |
57 | dh_testroot |
58 | rm -rf build-stamp .libs |
59 | -$(MAKE) clean |
60 | dh_clean --exclude ./_darcs/current/Makefile.orig --exclude ./Makefile.orig |
61 | |
62 | binary-indep: |
bb8c0b77 |
63 | |
ebb1f61c |
64 | binary-arch: apache13 apache20 |
bb8c0b77 |
65 | dh_testdir |
66 | dh_testroot |
67 | dh_installchangelogs |
68 | dh_installdocs |
69 | dh_installexamples |
bb8c0b77 |
70 | dh_installman |
71 | dh_link |
ebb1f61c |
72 | #dh_strip |
bb8c0b77 |
73 | dh_compress |
74 | dh_fixperms |
bb8c0b77 |
75 | dh_installdeb |
76 | dh_shlibdeps |
77 | dh_gencontrol |
78 | dh_md5sums |
79 | dh_builddeb |
80 | |
81 | binary: binary-indep binary-arch |
82 | .PHONY: build clean binary-indep binary-arch binary install configure |