]>
Commit | Line | Data |
---|---|---|
013101f0 | 1 | RELEASE=4.0 |
930e051d | 2 | |
07d9b3a0 | 3 | # source from http://www.corosync.org |
aeb347a9 | 4 | |
0a8764f4 | 5 | CSVERSION=2.3.5 |
df03257c | 6 | CSRELEASE=2 |
930e051d | 7 | CSDIR=corosync-${CSVERSION} |
013101f0 | 8 | CSSRC=corosync-${CSVERSION}.tar.gz |
930e051d DM |
9 | |
10 | ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH) | |
5aa0e5ba | 11 | GITVERSION:=$(shell cat .git/refs/heads/master) |
930e051d DM |
12 | |
13 | DEBS= \ | |
14 | corosync-pve_${CSVERSION}-${CSRELEASE}_${ARCH}.deb \ | |
15 | libcorosync4-pve_${CSVERSION}-${CSRELEASE}_${ARCH}.deb \ | |
16 | libcorosync-pve-dev_${CSVERSION}-${CSRELEASE}_${ARCH}.deb | |
17 | ||
18 | all: ${DEBS} | |
19 | echo ${DEBS} | |
20 | ||
21 | ${DEBS}: ${CSSRC} | |
22 | echo ${DEBS} | |
23 | rm -rf ${CSDIR} | |
24 | tar xf ${CSSRC} | |
25 | cp -a debian ${CSDIR}/debian | |
5aa0e5ba DM |
26 | echo "git clone git://git.proxmox.com/git/corosync-pve.git\\ngit checkout ${GITVERSION}" > ${CSDIR}/debian/SOURCE |
27 | ||
930e051d DM |
28 | cd ${CSDIR}; dpkg-buildpackage -rfakeroot -b -us -uc |
29 | ||
013101f0 DM |
30 | .PHONY: download |
31 | download: | |
df03257c | 32 | rm -rf ${CSSRC} ${CSSRC}.tmp ${CSDIR} |
d05fb358 | 33 | # wget http://build.clusterlabs.org/corosync/releases/${CSSRC} |
df03257c DM |
34 | git clone https://github.com/corosync/corosync.git -b needle ${CSDIR} |
35 | #cd ${CSDIR}; git checkout v${CSVERSION} | |
d05fb358 DM |
36 | cd ${CSDIR}; ./autogen.sh |
37 | tar czf ${CSSRC}.tmp ${CSDIR} | |
38 | mv ${CSSRC}.tmp ${CSSRC} | |
013101f0 | 39 | |
930e051d DM |
40 | .PHONY: upload |
41 | upload: ${DEBS} | |
42 | umount /pve/${RELEASE}; mount /pve/${RELEASE} -o rw | |
43 | mkdir -p /pve/${RELEASE}/extra | |
44 | rm -f /pve/${RELEASE}/extra/corosync*.deb | |
45 | rm -f /pve/${RELEASE}/extra/libcorosync*.deb | |
46 | rm -f /pve/${RELEASE}/extra/Packages* | |
47 | cp ${DEBS} /pve/${RELEASE}/extra | |
48 | cd /pve/${RELEASE}/extra; dpkg-scanpackages . /dev/null > Packages; gzip -9c Packages > Packages.gz | |
49 | umount /pve/${RELEASE}; mount /pve/${RELEASE} -o ro | |
50 | ||
01f3ad04 DM |
51 | distclean: clean |
52 | ||
930e051d DM |
53 | .PHONY: clean |
54 | clean: | |
55 | rm -rf *_${ARCH}.deb *.changes *.dsc ${CSDIR} corosync_${CSVERSION}-${CSRELEASE}.tar.gz | |
6e49b83c | 56 | find . -name '*~' -exec rm {} ';' |
930e051d DM |
57 | |
58 | .PHONY: dinstall | |
59 | dinstall: ${DEBS} | |
60 | dpkg -i ${DEBS} |