]> git.proxmox.com Git - lxc.git/blob - Makefile
bump version to 2.0.8-1
[lxc.git] / Makefile
1 PACKAGE=lxc-pve
2 LXCVER=2.0.8
3 DEBREL=1
4
5 SRCDIR=lxc
6 SRCTAR=${SRCDIR}.tgz
7
8 ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH)
9 GITVERSION:=$(shell cat .git/refs/heads/master)
10
11 DEB1=${PACKAGE}_${LXCVER}-${DEBREL}_${ARCH}.deb
12 DEB2=${PACKAGE}-dev_${LXCVER}-${DEBREL}_${ARCH}.deb \
13 ${PACKAGE}-dbg_${LXCVER}-${DEBREL}_${ARCH}.deb
14 DEBS=$(DEB1) $(DEB2)
15
16 all: ${DEBS}
17 echo ${DEBS}
18
19 .PHONY: deb
20 deb: ${DEBS}
21 $(DEB2): $(DEB1)
22 $(DEB1): ${SRCTAR}
23 rm -rf ${SRCDIR}
24 tar xf ${SRCTAR}
25 cp -a debian ${SRCDIR}/debian
26 echo "git clone git://git.proxmox.com/git/lxc.git\\ngit checkout ${GITVERSION}" > ${SRCDIR}/debian/SOURCE
27 cd ${SRCDIR}; dpkg-buildpackage -rfakeroot -b -us -uc
28 lintian ${DEBS}
29
30
31 .PHONY: download
32 download ${SRCTAR}:
33 rm -rf ${SRCDIR} ${SRCTAR}
34 git clone -b lxc-${LXCVER} git://github.com/lxc/lxc
35 tar czf ${SRCTAR}.tmp ${SRCDIR}
36 mv ${SRCTAR}.tmp ${SRCTAR}
37
38 .PHONY: upload
39 upload: ${DEBS}
40 tar cf - ${DEBS} | ssh repoman@repo.proxmox.com upload --product pve --dist stretch
41
42 distclean: clean
43
44 .PHONY: clean
45 clean:
46 rm -rf ${SRCDIR} ${SRCDIR}.tmp *_${ARCH}.deb *.changes *.dsc *.buildinfo
47 find . -name '*~' -exec rm {} ';'
48
49 .PHONY: dinstall
50 dinstall: ${DEBS}
51 dpkg -i ${DEBS}