]>
Commit | Line | Data |
---|---|---|
7b922beb DM |
1 | # howto add rule updates: |
2 | # edit paths ($srcdir) in changes.pl | |
3 | # update changes.diff - verify changes! | |
4 | ||
badcf991 | 5 | # dig -t any 2.4.3.updates.spamassassin.org |
7b922beb DM |
6 | # wget http://spamassassin.kluge.net/updates/501214.tar.gz |
7 | # wget http://spamassassin.kluge.net/updates/501214.tar.gz.asc | |
8 | # gpg --verify 501214.tar.gz.asc 501214.tar.gz | |
9 | # | |
10 | # or just use: make sa-updates.tgz (from the last stable version) | |
11 | # warning: start with an empty sa-updates.tgz, install the package, | |
12 | # the run sa-update to generate the updates | |
13 | # | |
d2ab4c52 DM |
14 | # Note: we also add KAM.cf from |
15 | # http://www.pccc.com/downloads/SpamAssassin/contrib/KAM.cf | |
16 | # | |
7b922beb DM |
17 | # edit debin/rules to apply updates |
18 | ||
03483955 | 19 | PKGREL=3 |
badcf991 | 20 | SAVER=3.4.2 |
7b922beb DM |
21 | OPKGNAME = Mail-SpamAssassin-${SAVER} |
22 | NPKGNAME = proxmox-spamassassin_${SAVER} | |
23 | DEB = proxmox-spamassassin_${SAVER}-${PKGREL}_amd64.deb | |
24 | ||
7a367109 DM |
25 | EXTRA_RULES = KAM.cf |
26 | ||
ae1e4fd8 SI |
27 | SA_UPDATE_GPG_DIR = .sa-update-gpghome |
28 | ||
f8a626c3 TL |
29 | deb: ${DEB} |
30 | ||
7b922beb | 31 | #${DEB}: ${OPKGNAME}.tar.gz |
7a367109 | 32 | ${DEB}: ${OPKGNAME}.tar.gz sa-updates.tgz ${EXTRA_RULES} |
7b922beb DM |
33 | -rm -rf ${OPKGNAME} ${NPKGNAME} |
34 | tar xzf ${OPKGNAME}.tar.gz | |
35 | mv ${OPKGNAME} ${NPKGNAME} | |
36 | cp -a debian ${NPKGNAME} | |
7a367109 DM |
37 | mkdir ${NPKGNAME}/extra_rules |
38 | cp ${EXTRA_RULES} ${NPKGNAME}/extra_rules | |
7b922beb DM |
39 | cd ${NPKGNAME}; dpkg-buildpackage -us -uc -rfakeroot |
40 | -rm -rf ${OPKGNAME} ${NPKGNAME} | |
41 | lintian ${DEB} | |
42 | ||
7a367109 DM |
43 | KAM.cf: |
44 | wget http://www.pccc.com/downloads/SpamAssassin/contrib/KAM.cf -O $@.tmp | |
45 | mv KAM.cf.tmp $@ | |
7b922beb | 46 | |
ae1e4fd8 SI |
47 | ${SA_UPDATE_GPG_DIR}/.prepared: ${OPKGNAME}.tar.gz |
48 | rm -rf ${SA_UPDATE_GPG_DIR} | |
49 | mkdir --mode=0700 -p ${SA_UPDATE_GPG_DIR} | |
50 | tar --strip-components 2 -xzf ${OPKGNAME}.tar.gz ${OPKGNAME}/rules/sa-update-pubkey.txt | |
51 | sa-update --gpghomedir ${SA_UPDATE_GPG_DIR} --import sa-update-pubkey.txt | |
52 | rm sa-update-pubkey.txt | |
53 | touch $@ | |
54 | ||
848fbe4c | 55 | sa-updates.tgz: | ${SA_UPDATE_GPG_DIR}/.prepared |
d2ab4c52 | 56 | rm -rf updates.tmp |
ae1e4fd8 | 57 | sa-update --gpghomedir ${SA_UPDATE_GPG_DIR} --updatedir updates.tmp --channel updates.spamassassin.org |
7b922beb DM |
58 | tar cvzf sa-updates.tgz --exclude=local.cf --exclude=regression_tests.cf --exclude=*.txt --exclude=MIRRORED.BY -C updates.tmp/updates_spamassassin_org/ . |
59 | ||
60 | .PHONY: upload | |
61 | upload: ${DEB} | |
f050a4b2 | 62 | tar cf - ${DEB} | ssh -X repoman@repo.proxmox.com -- upload --product pmg --dist stretch |
7b922beb | 63 | |
ae1e4fd8 | 64 | CLEANFILES = *~ debian/*~ *.deb proxmox-spamassassin_* updates.tmp ${SA_UPDATE_GPG_DIR} |
7b922beb DM |
65 | |
66 | .PHONY: clean | |
67 | clean: | |
68 | rm -rf ${CLEANFILES} | |
19fb7ca6 DM |
69 | |
70 | .PHONY: dinstall | |
71 | dinstall: ${DEB} | |
72 | dpkg -i ${DEB} |