]> git.proxmox.com Git - arch-pacman.git/blame - Makefile
makefile updates
[arch-pacman.git] / Makefile
CommitLineData
a009ec9d
WB
1RELEASE=4.2.1
2
3PACKAGE=arch-pacman
4PACMANVER=4.2.1
5DEBREL=1
6
7SRCDIR=pacman
8SRCTAR=${SRCDIR}.tgz
9
10ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH)
11GITVERSION:=$(shell cat .git/refs/heads/master)
12
13DEB=${PACKAGE}_${PACMANVER}-${DEBREL}_amd64.deb
14DEB2=${PACKAGE}-dev_${PACMANVER}-${DEBREL}_amd64.deb \
15 ${PACKAGE}-dbg_${PACMANVER}-${DEBREL}_amd64.deb
16
17DEBS= ${DEB} ${DEB2}
18
19all: ${DEBS}
20 echo ${DEBS}
21
22${DEB}: ${SRCTAR}
23 rm -rf ${SRCDIR}
24 tar xf ${SRCTAR}
25 cp -a debian ${SRCDIR}/debian
1e5ba461 26 echo "git clone git://projects.archlinux.org/pacman.git\\ngit checkout ${GITVERSION}" > ${SRCDIR}/debian/SOURCE
a009ec9d
WB
27 cd ${SRCDIR}; DEB_BUILD_OPTIONS=nocheck dpkg-buildpackage -rfakeroot -b -us -uc
28 lintian ${DEBS}
29
30.PHONY: deb
31deb ${DEB2}: ${DEB}
32
33.PHONY: download
34download ${SRCTAR}:
35 rm -rf ${SRCDIR} ${SRCTAR} pacman-git
36 git clone --depth=1 --branch=v${PACMANVER} git://projects.archlinux.org/pacman.git pacman-git
37 (cd pacman-git && git archive --prefix=${SRCDIR}/ --format=tar v${PACMANVER}) | gzip > ${SRCTAR}.tmp
38 mv ${SRCTAR}.tmp ${SRCTAR}
39 rm -rf pacman-git
40
a009ec9d
WB
41distclean: clean
42
43.PHONY: clean
44clean:
45 rm -rf ${SRCDIR} ${SRCDIR}.tmp *_${ARCH}.deb *.changes *.dsc
46 find . -name '*~' -exec rm {} ';'
47
48.PHONY: dinstall
49dinstall: ${DEBS}
50 dpkg -i ${DEBS}