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