Rev 68 | Go to most recent revision | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 68 | Rev 82 | ||
---|---|---|---|
1 | #!/usr/bin/make -f |
1 | #!/usr/bin/make -f |
2 | # Sample debian/rules that uses debhelper. |
2 | # Sample debian/rules that uses debhelper. |
3 | # GNU copyright 1997 to 1999 by Joey Hess. |
3 | # GNU copyright 1997 to 1999 by Joey Hess. |
4 | 4 | ||
5 | # Uncomment this to turn on verbose mode. |
5 | # Uncomment this to turn on verbose mode. |
6 | #export DH_VERBOSE=1 |
6 | #export DH_VERBOSE=1 |
7 | 7 | ||
8 | CFLAGS = -Wall -g |
8 | CFLAGS := $(shell dpkg-buildflags --get CFLAGS) |
9 | - | ||
10 | ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) |
9 | CPPFLAGS := $(shell dpkg-buildflags --get CPPFLAGS) |
11 | CFLAGS += -O0 |
- | |
12 | else |
- | |
13 | CFLAGS += -O2 |
10 | LDFLAGS := $(shell dpkg-buildflags --get LDFLAGS) |
14 | endif |
- | |
15 | 11 | ||
16 | build: build-arch |
12 | build: build-arch |
17 | 13 | ||
18 | build-indep: |
14 | build-indep: |
19 | 15 | ||
20 | build-arch: build-stamp |
16 | build-arch: build-stamp |
21 | build-stamp: |
17 | build-stamp: |
22 | dh_testdir |
18 | dh_testdir |
23 | $(MAKE) BUILDCFLAGS='-I/usr/include/exim4 -fPIC $$(CFLAGS)' SUFF='' |
19 | $(MAKE) BUILDCFLAGS='-I/usr/include/exim4 -fPIC $$(CPPFLAGS) $$(CFLAGS)' \ |
- | 20 | CPPFLAGS='$(CPPFLAGS)' CFLAGS='$(CFLAGS)' LDFLAGS='-shared $(LDFLAGS)' SUFF='' |
|
24 | touch build-stamp |
21 | touch build-stamp |
25 | 22 | ||
26 | clean: |
23 | clean: |
27 | dh_testdir |
24 | dh_testdir |
28 | dh_testroot |
25 | dh_testroot |
29 | rm -f build-stamp |
26 | rm -f build-stamp |
30 | $(MAKE) clean |
27 | $(MAKE) clean |
31 | dh_clean |
28 | dh_clean |
32 | 29 | ||
33 | # Build architecture-independent files here. |
30 | # Build architecture-independent files here. |
34 | binary-indep: |
31 | binary-indep: |
35 | # We have nothing to do by default. |
32 | # We have nothing to do by default. |
36 | 33 | ||
37 | # Build architecture-dependent files here. |
34 | # Build architecture-dependent files here. |
38 | binary-arch: build |
35 | binary-arch: build |
39 | dh_testdir |
36 | dh_testdir |
40 | dh_testroot |
37 | dh_testroot |
41 | dh_prep |
38 | dh_prep |
42 | dh_install |
39 | dh_install |
43 | dh_installchangelogs Changelog.html |
40 | dh_installchangelogs Changelog.html |
44 | dh_installdocs |
41 | dh_installdocs |
45 | dh_installexamples |
42 | dh_installexamples |
46 | dh_installdebconf |
43 | dh_installdebconf |
47 | dh_installman |
44 | dh_installman |
48 | dh_installcron --name=greylistclean |
45 | dh_installcron --name=greylistclean |
49 | dh_lintian |
46 | dh_lintian |
50 | dh_link |
47 | dh_link |
51 | dh_strip |
48 | dh_strip |
52 | dh_compress |
49 | dh_compress |
53 | dh_fixperms |
50 | dh_fixperms |
54 | dh_perl |
51 | dh_perl |
55 | dh_installdeb |
52 | dh_installdeb |
56 | dh_shlibdeps |
53 | dh_shlibdeps |
57 | echo "exim:Depends=exim4-localscanapi-`exim4-localscan-plugin-config --localscan-apiversion`" \ |
54 | echo "exim:Depends=exim4-localscanapi-`exim4-localscan-plugin-config --localscan-apiversion`" \ |
58 | >> debian/sa-exim.substvars |
55 | >> debian/sa-exim.substvars |
59 | dh_gencontrol |
56 | dh_gencontrol |
60 | dh_md5sums |
57 | dh_md5sums |
61 | dh_builddeb |
58 | dh_builddeb |
62 | 59 | ||
63 | binary: binary-indep binary-arch |
60 | binary: binary-indep binary-arch |
64 | .PHONY: build build-indep build-arch clean binary-indep binary-arch binary |
61 | .PHONY: build build-indep build-arch clean binary-indep binary-arch binary |