Rev 58 | Rev 68 | Go to most recent revision | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 58 | Rev 65 | ||
---|---|---|---|
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 = -Wall -g |
9 | 9 | ||
10 | ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) |
10 | ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) |
11 | CFLAGS += -O0 |
11 | CFLAGS += -O0 |
12 | else |
12 | else |
13 | CFLAGS += -O2 |
13 | CFLAGS += -O2 |
14 | endif |
14 | endif |
15 | ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS))) |
- | |
16 | INSTALL_PROGRAM += -s |
- | |
17 | endif |
- | |
18 | 15 | ||
19 | configure: configure-stamp |
16 | configure: configure-stamp |
20 | configure-stamp: |
17 | configure-stamp: |
21 | dh_testdir |
18 | dh_testdir |
22 | touch configure-stamp |
19 | touch configure-stamp |
23 | 20 | ||
24 | build: build-stamp |
21 | build: build-stamp |
25 | build-stamp: configure-stamp |
22 | build-stamp: configure-stamp |
26 | dh_testdir |
23 | dh_testdir |
27 | $(MAKE) BUILDCFLAGS='-I/usr/include/exim4 -fPIC $$(CFLAGS)' |
24 | $(MAKE) BUILDCFLAGS='-I/usr/include/exim4 -fPIC $$(CFLAGS)' |
28 | touch build-stamp |
25 | touch build-stamp |
29 | 26 | ||
30 | clean: |
27 | clean: |
31 | dh_testdir |
28 | dh_testdir |
32 | dh_testroot |
29 | dh_testroot |
33 | rm -f build-stamp configure-stamp |
30 | rm -f build-stamp configure-stamp |
34 | $(MAKE) clean |
31 | $(MAKE) clean |
35 | dh_clean |
32 | dh_clean |
36 | 33 | ||
37 | install: build |
34 | install: build |
38 | dh_testdir |
35 | dh_testdir |
39 | dh_testroot |
36 | dh_testroot |
40 | dh_clean -k |
37 | dh_clean -k |
41 | dh_installdirs |
38 | dh_installdirs |
42 | install -m755 sa-exim-*so \ |
39 | install -m755 sa-exim-*so \ |
43 | $(CURDIR)/debian/sa-exim/usr/lib/exim4/local_scan/sa-exim.so |
40 | $(CURDIR)/debian/sa-exim/usr/lib/exim4/local_scan/sa-exim.so |
44 | install -m755 accept*so \ |
41 | install -m755 accept*so \ |
45 | $(CURDIR)/debian/sa-exim/usr/lib/exim4/local_scan/accept.so |
42 | $(CURDIR)/debian/sa-exim/usr/lib/exim4/local_scan/accept.so |
46 | sed "s/\/var\/spool\/exim/\/var\/spool\/sa-exim/" < sa-exim.conf > \ |
43 | sed "s/\/var\/spool\/exim/\/var\/spool\/sa-exim/" < sa-exim.conf > \ |
47 | $(CURDIR)/debian/sa-exim/etc/exim4/sa-exim.conf |
44 | $(CURDIR)/debian/sa-exim/etc/exim4/sa-exim.conf |
48 | chmod 644 $(CURDIR)/debian/sa-exim/etc/exim4/sa-exim.conf |
45 | chmod 644 $(CURDIR)/debian/sa-exim/etc/exim4/sa-exim.conf |
49 | install -m644 debian/15_sa-exim_plugin_path \ |
46 | install -m644 debian/15_sa-exim_plugin_path \ |
50 | $(CURDIR)/debian/sa-exim/etc/exim4/conf.d/main |
47 | $(CURDIR)/debian/sa-exim/etc/exim4/conf.d/main |
51 | install -m644 Greylisting.pm \ |
48 | install -m644 Greylisting.pm \ |
52 | $(CURDIR)/debian/sa-exim/usr/share/perl5/Mail/SpamAssassin/Plugin/Greylisting.pm |
49 | $(CURDIR)/debian/sa-exim/usr/share/perl5/Mail/SpamAssassin/Plugin/Greylisting.pm |
53 | install -m644 greylistclean.cron \ |
50 | install -m644 greylistclean.cron \ |
54 | $(CURDIR)/debian/sa-exim/etc/cron.d/greylistclean |
51 | $(CURDIR)/debian/sa-exim/etc/cron.d/greylistclean |
55 | install -m755 greylistclean \ |
52 | install -m755 greylistclean \ |
56 | $(CURDIR)/debian/sa-exim/usr/share/sa-exim/greylistclean |
53 | $(CURDIR)/debian/sa-exim/usr/share/sa-exim/greylistclean |
57 | 54 | ||
58 | # Build architecture-independent files here. |
55 | # Build architecture-independent files here. |
59 | binary-indep: build install |
56 | binary-indep: build install |
60 | # We have nothing to do by default. |
57 | # We have nothing to do by default. |
61 | 58 | ||
62 | # Build architecture-dependent files here. |
59 | # Build architecture-dependent files here. |
63 | binary-arch: build install |
60 | binary-arch: build install |
64 | dh_testdir |
61 | dh_testdir |
65 | dh_testroot |
62 | dh_testroot |
66 | dh_installchangelogs Changelog.html |
63 | dh_installchangelogs Changelog.html |
67 | dh_installdocs |
64 | dh_installdocs |
68 | dh_installexamples |
65 | dh_installexamples |
69 | dh_installdebconf |
66 | dh_installdebconf |
70 | dh_installman |
67 | dh_installman |
71 | install -d debian/sa-exim/usr/share/lintian/overrides |
68 | install -d debian/sa-exim/usr/share/lintian/overrides |
72 | install -m 644 debian/sa-exim.lintian-overrides \ |
69 | install -m 644 debian/sa-exim.lintian-overrides \ |
73 | debian/sa-exim/usr/share/lintian/overrides/sa-exim |
70 | debian/sa-exim/usr/share/lintian/overrides/sa-exim |
74 | dh_link |
71 | dh_link |
75 | dh_strip |
72 | dh_strip |
76 | dh_compress |
73 | dh_compress |
77 | dh_fixperms -Xvar/spool/sa-exim |
74 | dh_fixperms |
78 | dh_perl |
75 | dh_perl |
79 | dh_installdeb |
76 | dh_installdeb |
80 | dh_shlibdeps |
77 | dh_shlibdeps |
81 | echo "exim:Depends=exim4-localscanapi-`exim4-localscan-plugin-config --localscan-apiversion`" \ |
78 | echo "exim:Depends=exim4-localscanapi-`exim4-localscan-plugin-config --localscan-apiversion`" \ |
82 | >> debian/sa-exim.substvars |
79 | >> debian/sa-exim.substvars |
83 | dh_gencontrol |
80 | dh_gencontrol |
84 | dh_md5sums |
81 | dh_md5sums |
85 | dh_builddeb |
82 | dh_builddeb |
86 | 83 | ||
87 | binary: binary-indep binary-arch |
84 | binary: binary-indep binary-arch |
88 | .PHONY: build clean binary-indep binary-arch binary install configure |
85 | .PHONY: build clean binary-indep binary-arch binary install configure |