]> git.proxmox.com Git - proxmox-widget-toolkit.git/blob - Makefile
improve error handling when adding webauthn entries
[proxmox-widget-toolkit.git] / Makefile
1 include /usr/share/dpkg/pkg-info.mk
2 export DEB_VERSION_UPSTREAM_REVISION
3
4 export PACKAGE=proxmox-widget-toolkit
5
6 DEB=${PACKAGE}_${DEB_VERSION_UPSTREAM_REVISION}_all.deb
7 DEV_DEB=${PACKAGE}-dev_${DEB_VERSION_UPSTREAM_REVISION}_all.deb
8
9 DEBS=${DEB} ${DEV_DEB}
10 DSC=${PACKAGE}_${DEB_VERSION_UPSTREAM_REVISION}.dsc
11
12 BUILDDIR ?= ${PACKAGE}-${DEB_VERSION_UPSTREAM}
13
14 ${BUILDDIR}: GITVERSION:=$(shell git rev-parse HEAD)
15 ${BUILDDIR}:
16 rm -rf ${BUILDDIR} ${BUILDDIR}.tmp
17 cp -a src/ ${BUILDDIR}.tmp
18 cp -a debian ${BUILDDIR}.tmp/
19 echo "git clone git://git.proxmox.com/git/proxmox-widget-toolkit.git\\ngit checkout ${GITVERSION}" > ${BUILDDIR}.tmp/debian/SOURCE
20 mv ${BUILDDIR}.tmp/ ${BUILDDIR}
21
22 .PHONY: deb
23 deb: ${DEBS}
24 ${DEBS}: ${BUILDDIR}
25 cd ${BUILDDIR}; dpkg-buildpackage -b -us -uc
26 lintian ${DEBS}
27
28 .PHONY: dsc
29 dsc: ${DSC}
30 ${DSC}: ${BUILDDIR}
31 cd ${BUILDDIR}; dpkg-buildpackage -S -us -uc -d
32 lintian ${DSC}
33
34 .PHONY: lint
35 lint: ${JSSRC}
36 ${MAKE} -C src lint
37
38 .PHONY: upload
39 upload: ${DEBS}
40 tar cf - ${DEB} | ssh -X repoman@repo.proxmox.com -- upload --product pve,pmg,pbs --dist bullseye
41 tar cf - ${DEV_DEB} | ssh -X repoman@repo.proxmox.com -- upload --product devel --dist bullseye
42
43 distclean: clean
44 clean:
45 $(MAKE) -C src clean
46 rm -rf ${BUILDDIR} ${BUILDDIR}.tmp *.tar.gz *.dsc *.deb *.changes *.buildinfo
47 find . -name '*~' -exec rm {} ';'
48
49 .PHONY: dinstall
50 dinstall: ${DEBS}
51 dpkg -i ${DEBS}