]>
Commit | Line | Data |
---|---|---|
1 | include /usr/share/dpkg/pkg-info.mk | |
2 | include /usr/share/dpkg/architecture.mk | |
3 | ||
4 | PACKAGE=criu | |
5 | ||
6 | SRCDIR=criu | |
7 | SRCTAR=${SRCDIR}.tgz | |
8 | ||
9 | GITVERSION:=$(shell cat .git/refs/heads/master) | |
10 | ||
11 | DEB1=${PACKAGE}_${DEB_VERSION_UPSTREAM_REVISION}_${DEB_BUILD_ARCH}.deb | |
12 | DEB_DBG=${PACKAGE}-dbgsym_${DEB_VERSION_UPSTREAM_REVISION}_${DEB_BUILD_ARCH}.deb | |
13 | DEBS=$(DEB1) $(DEB_DBG) | |
14 | ||
15 | all: ${DEBS} | |
16 | echo ${DEBS} | |
17 | ||
18 | .PHONY: deb | |
19 | deb $(DEB_DBG): $(DEB1) | |
20 | $(DEB1): $(SRCTAR) | |
21 | rm -rf ${SRCDIR} | |
22 | tar xf ${SRCTAR} | |
23 | mv ${SRCDIR}/debian/changelog ${SRCDIR}/debian/changelog.org | |
24 | cat debian/changelog ${SRCDIR}/debian/changelog.org > ${SRCDIR}/debian/changelog | |
25 | echo "git clone git://git.proxmox.com/git/criu.git\\ngit checkout ${GITVERSION}" > ${SRCDIR}/debian/SOURCE | |
26 | cd ${SRCDIR}; dpkg-buildpackage -b -us -uc | |
27 | lintian ${DEBS} | |
28 | ||
29 | ||
30 | .PHONY: download | |
31 | download: | |
32 | rm -rf ${SRCDIR} ${SRCTAR} | |
33 | git clone -b debian/3.11-2 https://anonscm.debian.org/git/collab-maint/criu.git ${SRCDIR} | |
34 | tar czf ${SRCTAR}.tmp --exclude=.git ${SRCDIR} | |
35 | mv ${SRCTAR}.tmp ${SRCTAR} | |
36 | ||
37 | .PHONY: upload | |
38 | upload: ${DEBS} | |
39 | tar cf - ${DEBS} | ssh repoman@repo.proxmox.com -- upload --product pve --dist buster --arch ${DEB_BUILD_ARCH} | |
40 | ||
41 | distclean: clean | |
42 | ||
43 | .PHONY: clean | |
44 | clean: | |
45 | rm -rf ${SRCDIR} ${SRCDIR}.tmp *_${DEB_BUILD_ARCH}.deb *.changes *.dsc *.buildinfo | |
46 | find . -name '*~' -exec rm {} ';' | |
47 | ||
48 | .PHONY: dinstall | |
49 | dinstall: ${DEBS} | |
50 | dpkg -i ${DEBS} |