X-Git-Url: https://git.proxmox.com/?p=iproute2.git;a=blobdiff_plain;f=Makefile;h=8f34d88457ffcaad6f7612ff7731913ed00c93cd;hp=6c62713ac53092732dde570763f4166f7f223d34;hb=e4fb63fa12f9f1dd8a75c50aa5d845b2bf02534d;hpb=e218e6b64747218470700257d240b580562e21eb diff --git a/Makefile b/Makefile index 6c62713..8f34d88 100644 --- a/Makefile +++ b/Makefile @@ -1,48 +1,56 @@ -RELEASE=4.2 +PACKAGE=iproute2 +VER=4.15.0 +PKGREL=5 -VERSION=4.4.0 -PKGREL=1 - -DIR=iproute2-${VERSION} -SRC=iproute2-${VERSION}.orig.tar.gz +SRCDIR=iproute2 +BUILDDIR=${SRCDIR}.tmp ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH) -DEBS= \ +MAIN_DEB=iproute2_${VERSION}-${PKGREL}_${ARCH}.deb +OTHER_DEBS=\ iproute2-doc_${VERSION}-${PKGREL}_all.deb \ - iproute2_${VERSION}-${PKGREL}_${ARCH}.deb + iproute2-dbgsym_${VERSION}-${PKGREL}_all.deb \ -all: ${DEBS} - echo ${DEBS} +DEBS=${MAIN_DEB} ${OTHER_DEBS} -${DEBS}: ${SRC} - rm -rf ${DIR} - tar xf ${SRC} - cp -a debian ${DIR}/debian - cd ${DIR}; dpkg-buildpackage -rfakeroot -b -us -uc +DSC=${PACKAGE}_${VER}-${PKGREL}.dsc +all: ${DEBS} + echo ${DEBS} -download: - rm -rf iproute2-${VERSION} iproute2-${VERSION}.orig.tar.gz - git clone git://git.kernel.org/pub/scm/linux/kernel/git/shemminger/iproute2.git iproute2-${VERSION} - cd iproute2-${VERSION}; git checkout v4.2.0; - tar czf iproute2-${VERSION}.orig.tar.gz iproute2-${VERSION}/ +.PHONY: submodule +submodule: + test -f "${SRCDIR}/README" || git submodule update --init + +${BUILDDIR}: | submodule + rm -rf $(BUILDDIR) + cp -a $(SRCDIR) $(BUILDDIR) + cp -a debian $(BUILDDIR)/debian + +.PHONY: deb +deb: ${DEBS} +${OTHER_DEBS}: ${MAIN_DEBS} +${MAIN_DEB}: ${BUILDDIR} + cd ${BUILDDIR}; dpkg-buildpackage -b -uc -us + +.PHONY: dsc +dsc: ${DSC} +${DSC}: ${BUILDDIR} + cd ${BUILDDIR}; debian/rules clean + cd ${BUILDDIR}; tar czf ../${PACKAGE}_${VER}.orig.tar.gz * + cd ${BUILDDIR}; dpkg-buildpackage -S -uc -us -d + lintian $@ .PHONY: upload upload: ${DEBS} - umount /pve/${RELEASE}; mount /pve/${RELEASE} -o rw - mkdir -p /pve/${RELEASE}/extra - rm -f /pve/${RELEASE}/extra/iproute2_*.deb - rm -f /pve/${RELEASE}/extra/iproute2-doc_*.deb - rm -f /pve/${RELEASE}/extra/Packages* - cp ${DEBS} /pve/${RELEASE}/extra - cd /pve/${RELEASE}/extra; dpkg-scanpackages . /dev/null > Packages; gzip -9c Packages > Packages.gz - umount /pve/${RELEASE}; mount /pve/${RELEASE} -o ro - -.PHONY: clean + tar cf - ${DEBS} | ssh repoman@repo.proxmox.com -- upload --product pve --dist stretch --arch ${ARCH} + +.PHONY: clean distclean +distclean: clean clean: - rm -rf *~ debian/*~ *.changes *.dsc ${DIR} iproute2_${VERSION}.orig.tar.gz *.deb + rm -rf ${BUILDDIR} *.deb *.changes *.dsc *.buildinfo *.orig.tar.* *.debian.tar.* .PHONY: dinstall -dinstall: ${DEBS} - dpkg -i ${DEBS} +dinstall: deb + dpkg -i ${DEB}