]> git.proxmox.com Git - pve-apiclient.git/blob - Makefile
example2.pl: add a second example
[pve-apiclient.git] / Makefile
1 PACKAGE=libpve-apiclient-perl
2 PKGVER=1.0
3 PKGREL=2
4
5 DEB=${PACKAGE}_${PKGVER}-${PKGREL}_all.deb
6
7 DESTDIR=
8
9 PERL5DIR=${DESTDIR}/usr/share/perl5
10 DOCDIR=${DESTDIR}/usr/share/doc/${PACKAGE}
11
12 all: ${DEB}
13
14 .PHONY: deb
15 deb ${DEB}:
16 rm -rf build
17 rsync -a debian build
18 make DESTDIR=./build install
19 cd build; dpkg-buildpackage -rfakeroot -b -us -uc
20 lintian ${DEB}
21
22 install:
23 install -D -m 0644 PVE/APIClient/LWP.pm ${PERL5DIR}/PVE/APIClient/LWP.pm
24 install -d -m 755 ${DOCDIR}/examples
25 install -m 0755 examples/example1.pl ${DOCDIR}/examples
26 install -m 0755 examples/example2.pl ${DOCDIR}/examples
27
28 .PHONY: upload
29 upload: ${DEB}
30 tar cf - ${DEB} | ssh repoman@repo.proxmox.com upload
31
32 distclean: clean
33
34 clean:
35 rm -rf ./build *.deb *.changes
36 find . -name '*~' -exec rm {} ';'
37
38 .PHONY: dinstall
39 dinstall: ${DEB}
40 dpkg -i ${DEB}