]> git.proxmox.com Git - proxmox-widget-toolkit.git/blame_incremental - Makefile
makefile: convert to use simple parenthesis
[proxmox-widget-toolkit.git] / Makefile
... / ...
CommitLineData
1include /usr/share/dpkg/pkg-info.mk
2export DEB_VERSION_UPSTREAM_REVISION
3
4export PACKAGE=proxmox-widget-toolkit
5
6DEB=$(PACKAGE)_$(DEB_VERSION_UPSTREAM_REVISION)_all.deb
7DEV_DEB=$(PACKAGE)-dev_$(DEB_VERSION_UPSTREAM_REVISION)_all.deb
8
9DEBS=$(DEB) $(DEV_DEB)
10DSC=$(PACKAGE)_$(DEB_VERSION_UPSTREAM_REVISION).dsc
11
12BUILDDIR ?= $(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
23deb: $(DEBS)
24$(DEBS): $(BUILDDIR)
25 cd $(BUILDDIR); dpkg-buildpackage -b -us -uc
26 lintian $(DEBS)
27
28.PHONY: dsc
29dsc: $(DSC)
30$(DSC): $(BUILDDIR)
31 cd $(BUILDDIR); dpkg-buildpackage -S -us -uc -d
32 lintian $(DSC)
33
34.PHONY: lint
35lint: $(JSSRC)
36 $(MAKE) -C src lint
37
38.PHONY: upload
39upload: UPLOAD_DIST ?= $(DEB_DISTRIBUTION)
40upload: $(DEBS)
41 tar cf - $(DEB) | ssh -X repoman@repo.proxmox.com -- upload --product pve,pmg,pbs --dist $(UPLOAD_DIST)
42 tar cf - $(DEV_DEB) | ssh -X repoman@repo.proxmox.com -- upload --product devel --dist $(UPLOAD_DIST)
43
44distclean: clean
45clean:
46 $(MAKE) -C src clean
47 rm -rf $(PACKAGE)-[0-9]*/ *.tar.* *.dsc *.deb *.changes *.buildinfo *.build
48
49.PHONY: dinstall
50dinstall: $(DEBS)
51 dpkg -i $(DEBS)