]> git.proxmox.com Git - criu.git/blobdiff - Makefile
buildsys: switch upload dist over to buster
[criu.git] / Makefile
index 1a434e4a1c495cfdb97e2e5d2efbf1bce253c038..04ad80e2cdee0c7bd0ea37c6138e93310f3107e0 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,17 +1,15 @@
-RELEASE=5.0
+include /usr/share/dpkg/pkg-info.mk
+include /usr/share/dpkg/architecture.mk
 
 PACKAGE=criu
-PKGVER=2.11.1
-DEBREL=1~bpo90
 
 SRCDIR=criu
 SRCTAR=${SRCDIR}.tgz
 
-ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH)
 GITVERSION:=$(shell cat .git/refs/heads/master)
 
-DEB1=${PACKAGE}_${PKGVER}-${DEBREL}_$(ARCH).deb
-DEB_DBG=${PACKAGE}-dbgsym_${PKGVER}-${DEBREL}_$(ARCH).deb
+DEB1=${PACKAGE}_${DEB_VERSION_UPSTREAM_REVISION}_${DEB_BUILD_ARCH}.deb
+DEB_DBG=${PACKAGE}-dbgsym_${DEB_VERSION_UPSTREAM_REVISION}_${DEB_BUILD_ARCH}.deb
 DEBS=$(DEB1) $(DEB_DBG)
 
 all: ${DEBS}
@@ -23,7 +21,7 @@ $(DEB1): $(SRCTAR)
        rm -rf ${SRCDIR}
        tar xf ${SRCTAR}
        mv ${SRCDIR}/debian/changelog ${SRCDIR}/debian/changelog.org
-       cat changelog.Debian ${SRCDIR}/debian/changelog.org > ${SRCDIR}/debian/changelog
+       cat debian/changelog ${SRCDIR}/debian/changelog.org > ${SRCDIR}/debian/changelog
        echo "git clone git://git.proxmox.com/git/criu.git\\ngit checkout ${GITVERSION}" >  ${SRCDIR}/debian/SOURCE
        cd ${SRCDIR}; dpkg-buildpackage -b -us -uc
        lintian ${DEBS}
@@ -32,19 +30,19 @@ $(DEB1): $(SRCTAR)
 .PHONY: download
 download:
        rm -rf ${SRCDIR} ${SRCTAR}
-       git clone -b debian/2.11.1-1 https://anonscm.debian.org/git/collab-maint/criu.git ${SRCDIR}
+       git clone -b debian/3.11-2 https://anonscm.debian.org/git/collab-maint/criu.git ${SRCDIR}
        tar czf ${SRCTAR}.tmp --exclude=.git ${SRCDIR}
        mv ${SRCTAR}.tmp ${SRCTAR}
 
 .PHONY: upload
 upload: ${DEBS}
-       tar cf - ${DEBS} | ssh repoman@repo.proxmox.com -- upload --product pve --dist stretch --arch ${ARCH}
+       tar cf - ${DEBS} | ssh repoman@repo.proxmox.com -- upload --product pve --dist buster --arch ${DEB_BUILD_ARCH}
 
 distclean: clean
 
 .PHONY: clean
 clean:
-       rm -rf ${SRCDIR} ${SRCDIR}.tmp *_${ARCH}.deb *.changes *.dsc *.buildinfo
+       rm -rf ${SRCDIR} ${SRCDIR}.tmp *_${DEB_BUILD_ARCH}.deb *.changes *.dsc *.buildinfo
        find . -name '*~' -exec rm {} ';'
 
 .PHONY: dinstall