]> git.proxmox.com Git - corosync-pve.git/blob - Makefile
bump version to 2.4.2-2~pve4+2
[corosync-pve.git] / Makefile
1 RELEASE=4.2
2
3 # source from http://www.corosync.org
4
5 CSVERSION=2.4.2
6 CSRELEASE=2~pve4+2
7 CSDIR=corosync-${CSVERSION}
8 CSSRC=corosync-${CSVERSION}.tar.gz
9
10 ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH)
11 GITVERSION:=$(shell cat .git/refs/heads/master)
12
13 DEB1 := corosync-pve_${CSVERSION}-${CSRELEASE}_${ARCH}.deb
14
15 DEB2 := libcorosync4-pve_${CSVERSION}-${CSRELEASE}_${ARCH}.deb \
16 libcorosync-pve-dev_${CSVERSION}-${CSRELEASE}_${ARCH}.deb
17
18 DEBS := $(DEB1) $(DEB2)
19
20 all: ${DEBS}
21 echo ${DEBS}
22
23 .PHONY: deb
24 deb: $(DEB1)
25 $(DEB2): $(DEB1)
26 ${DEB1}: ${CSSRC}
27 rm -rf ${CSDIR}
28 tar xf ${CSSRC}
29 cp -a debian ${CSDIR}/debian
30 echo "git clone git://git.proxmox.com/git/corosync-pve.git\\ngit checkout ${GITVERSION}" > ${CSDIR}/debian/SOURCE
31
32 cd ${CSDIR}; dpkg-buildpackage -b -us -uc
33
34 .PHONY: download
35 download:
36 rm -rf ${CSSRC} ${CSSRC}.tmp ${CSDIR}
37 # wget http://build.clusterlabs.org/corosync/releases/${CSSRC}
38 git clone https://github.com/corosync/corosync.git -b needle ${CSDIR}
39 cd ${CSDIR}; git checkout v${CSVERSION}
40 cd ${CSDIR}; ./autogen.sh
41 tar czf ${CSSRC}.tmp ${CSDIR}
42 mv ${CSSRC}.tmp ${CSSRC}
43
44 .PHONY: upload
45 upload: ${DEBS}
46 tar cf - ${DEBS} | ssh repoman@repo.proxmox.com -- upload --product pve --dist jessie --arch ${ARCH}
47
48 distclean: clean
49
50 .PHONY: clean
51 clean:
52 rm -rf *_${ARCH}.deb *.changes *.dsc ${CSDIR} corosync_${CSVERSION}-${CSRELEASE}.tar.gz
53 find . -name '*~' -exec rm {} ';'
54
55 .PHONY: dinstall
56 dinstall: ${DEBS}
57 dpkg -i ${DEBS}