]>
Commit | Line | Data |
---|---|---|
1 | RELEASE=4.0 | |
2 | ||
3 | # Note: compile as root fail, so you need to do that as unpriv. user | |
4 | ||
5 | TARVER=1.27.1 | |
6 | DEBREL=2 | |
7 | PVETARVER=${TARVER}+pve.2 | |
8 | ||
9 | # also update changelog | |
10 | ||
11 | TARSRC=tar_${TARVER}.orig.tar.xz | |
12 | TARDEBSRC=tar_${TARVER}-${DEBREL}.debian.tar.xz | |
13 | TARDIR=tar-${TARVER} | |
14 | ||
15 | ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH) | |
16 | GITVERSION:=$(shell cat .git/refs/heads/master) | |
17 | SOURCETXT="git clone git://git.proxmox.com/git/tar.git\\ngit checkout ${GITVERSION}" | |
18 | ||
19 | DEB=tar_${PVETARVER}_${ARCH}.deb | |
20 | ||
21 | all: deb | |
22 | ||
23 | .PHONY: dinstall | |
24 | dinstall: deb | |
25 | dpkg -i ${DEB} | |
26 | ||
27 | .PHONY: deb | |
28 | deb ${DEB}: ${TARSRC} | |
29 | rm -rf ${TARDIR} | |
30 | tar xf ${TARSRC} | |
31 | cd ${TARDIR}; tar xf ../${TARDEBSRC} | |
32 | echo "${SOURCETXT}" > ${TARDIR}/debian/SOURCE | |
33 | echo "debian/SOURCE" >>${TARDIR}/debian/docs | |
34 | mv ${TARDIR}/debian/changelog ${TARDIR}/debian/changelog.org | |
35 | cat changelog ${TARDIR}/debian/changelog.org >${TARDIR}/debian/changelog | |
36 | cd ${TARDIR}; dpkg-buildpackage -b -uc -us | |
37 | ||
38 | .PHONY: upload | |
39 | upload: | |
40 | # this is no longer required | |
41 | false | |
42 | umount /pve/${RELEASE}; mount /pve/${RELEASE} -o rw | |
43 | mkdir -p /pve/${RELEASE}/extra | |
44 | rm -rf /pve/${RELEASE}/extra/apt-transport-https_*.deb | |
45 | rm -rf /pve/${RELEASE}/extra/Packages* | |
46 | cp ${DEB} /pve/${RELEASE}/extra | |
47 | cd /pve/${RELEASE}/extra; dpkg-scanpackages . /dev/null > Packages; gzip -9c Packages > Packages.gz | |
48 | umount /pve/${RELEASE}; mount /pve/${RELEASE} -o ro | |
49 | ||
50 | .PHONY: clean | |
51 | clean: | |
52 | rm -rf *~ *_${ARCH}.deb *_all.deb *_${ARCH}.udeb *.changes *.dsc ${TARDIR} |