bump version to 4.4-2, set RELEASE=4.2
[iproute2.git] / Makefile
1 RELEASE=4.2
2
3 VERSION=4.4.0
4 PKGREL=2
5
6 DIR=iproute2-${VERSION}
7 SRC=iproute2-${VERSION}.orig.tar.gz
8
9 ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH)
10
11 DEBS=                                                   \
12         iproute2-doc_${VERSION}-${PKGREL}_all.deb       \
13         iproute2_${VERSION}-${PKGREL}_${ARCH}.deb
14
15 all: ${DEBS}
16         echo ${DEBS}
17
18 .PHONY: deb
19 ${DEBS} deb: ${SRC}
20         rm -rf ${DIR}
21         tar xf ${SRC} 
22         cp -a debian ${DIR}/debian
23         cd ${DIR}; dpkg-buildpackage -rfakeroot -b -us -uc
24
25
26 download:
27         rm -rf iproute2-${VERSION} iproute2-${VERSION}.orig.tar.gz
28         git clone -b v${VERSION} --depth=1 git://git.kernel.org/pub/scm/linux/kernel/git/shemminger/iproute2.git iproute2-${VERSION}
29         tar czf iproute2-${VERSION}.orig.tar.gz iproute2-${VERSION}/
30
31 .PHONY: upload
32 upload: ${DEBS}
33         umount /pve/${RELEASE}; mount /pve/${RELEASE} -o rw
34         mkdir -p /pve/${RELEASE}/extra
35         rm -f /pve/${RELEASE}/extra/iproute2_*.deb
36         rm -f /pve/${RELEASE}/extra/iproute2-doc_*.deb
37         rm -f /pve/${RELEASE}/extra/Packages*
38         cp ${DEBS} /pve/${RELEASE}/extra
39         cd /pve/${RELEASE}/extra; dpkg-scanpackages . /dev/null > Packages; gzip -9c Packages > Packages.gz
40         umount /pve/${RELEASE}; mount /pve/${RELEASE} -o ro
41
42 .PHONY: clean
43 clean:
44         rm -rf *~ debian/*~ *.changes *.dsc ${DIR} iproute2_${VERSION}.orig.tar.gz *.deb
45
46 .PHONY: dinstall
47 dinstall: ${DEBS}
48         dpkg -i ${DEBS}