]> git.proxmox.com Git - iproute2.git/blame - Makefile
buildsys: refactor and clean makefile
[iproute2.git] / Makefile
CommitLineData
0234a966
AD
1PACKAGE=iproute2
2VER=4.15.0
3PKGREL=5
c9fc61fd 4
0234a966
AD
5SRCDIR=iproute2
6BUILDDIR=${SRCDIR}.tmp
3cf71090 7
c9fc61fd 8ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH)
3cf71090 9
f00001fe
DM
10DEBS= \
11 iproute2-doc_${VERSION}-${PKGREL}_all.deb \
12 iproute2_${VERSION}-${PKGREL}_${ARCH}.deb
3cf71090
DM
13
14all: ${DEBS}
15 echo ${DEBS}
16
0234a966
AD
17.PHONY: submodule
18submodule:
19 test -f "${SRCDIR}/README" || git submodule update --init
3cf71090 20
0234a966
AD
21.PHONY: deb
22${DEBS} deb: | submodule
0234a966 23 rm -rf $(BUILDDIR)
dc9d6863
TL
24 cp -a $(SRCDIR) $(BUILDDIR)
25 cp -a debian $(BUILDDIR)/debian
0234a966 26 cd ${BUILDDIR}; dpkg-buildpackage -rfakeroot -b -uc -us
3cf71090
DM
27
28.PHONY: upload
29upload: ${DEBS}
ced20272 30 tar cf - ${DEBS} | ssh repoman@repo.proxmox.com -- upload --product pve --dist stretch --arch ${ARCH}
3cf71090 31
dc9d6863 32.PHONY: clean distclean
0234a966 33distclean: clean
3cf71090 34clean:
0234a966 35 rm -rf ${BUILDDIR} *.deb *.changes *.dsc *.buildinfo
3cf71090
DM
36
37.PHONY: dinstall
0234a966
AD
38dinstall: deb
39 dpkg -i ${DEB}