]> git.proxmox.com Git - libjs-qrcodejs.git/blob - Makefile
buildsys: use full DEB_VERSION
[libjs-qrcodejs.git] / Makefile
1 include /usr/share/dpkg/pkg-info.mk
2
3 PACKAGE=libjs-qrcodejs
4 BUILDDIR ?= $(PACKAGE)-$(DEB_VERSION)
5 ORIG_SRC_TAR=$(PACKAGE)_$(DEB_VERSION_UPSTREAM).orig.tar.gz
6
7 DEB=$(PACKAGE)_$(DEB_VERSION)_all.deb
8 DSC=$(PACKAGE)_$(DEB_VERSION).dsc
9
10 GITVERSION:=$(shell git rev-parse HEAD)
11
12 all:
13 true
14
15 $(BUILDDIR):
16 rm -rf $(BUILDDIR).tmp
17 mkdir $(BUILDDIR).tmp
18 cp -a debian qrcode.min.js $(BUILDDIR).tmp/
19 echo "git clone git://git.proxmox.com/git/libjs-qrcodejs.git\\ngit checkout $(GITVERSION)" > $(BUILDDIR).tmp/debian/SOURCE
20 mv $(BUILDDIR).tmp/ $(BUILDDIR)
21
22 .PHONY: deb
23 deb: $(DEB)
24 $(DEB): $(BUILDDIR)
25 cd $(BUILDDIR); dpkg-buildpackage -b -us -uc
26 lintian $(DEB)
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: upload
35 upload: $(DEB)
36 tar cf - $(DEB) | ssh -X repoman@repo.proxmox.com -- upload --product pve,pmg,pbs --dist buster
37
38 distclean: clean
39 clean:
40 $(MAKE) -C src clean
41 rm -rf $(BUILDDIR) $(BUILDDIR).tmp *.tar.gz *.dsc *.deb *.changes *.buildinfo
42 find . -name '*~' -exec rm {} ';'
43
44 .PHONY: dinstall
45 dinstall: $(DEB)
46 dpkg -i $(DEB)