]> git.proxmox.com Git - novnc-pve.git/blobdiff - Makefile
bump version to 1.4.0-3
[novnc-pve.git] / Makefile
index b4d8a338fccfed98d9c4885ce620d83ded77754f..431dff95abcac03242e9da0ba83be66997507ccd 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,9 +1,10 @@
-include /usr/share/dpkg/pkg-info.mk
+include /usr/share/dpkg/default.mk
 
 PACKAGE=novnc-pve
 
 SRCDIR=novnc
 BUILDDIR=$(SRCDIR).tmp
+ORIG_SRC_TAR=$(PACKAGE)_$(DEB_VERSION_UPSTREAM).orig.tar.gz
 
 GITVERSION:=$(shell git rev-parse HEAD)
 
@@ -26,12 +27,18 @@ $(DEB): $(BUILDDIR)
        lintian $(DEB)
        @echo $(DEB)
 
+$(ORIG_SRC_TAR): $(BUILDDIR)
+       tar czf $(ORIG_SRC_TAR) --exclude="$(BUILDDIR)/debian" $(BUILDDIR)
+
 .PHONY: dsc
 dsc: $(DSC)
-$(DSC): $(BUILDDIR)
+$(DSC): $(ORIG_SRC_TAR) $(BUILDDIR)
        cd $(BUILDDIR); dpkg-buildpackage -S -uc -us -d
        lintian $(DSC)
 
+sbuild: $(DSC)
+       sbuild $(DSC)
+
 .PHONY: submodule
 submodule:
        test -f "$(SRCDIR)/package.json" || git submodule update --init
@@ -41,15 +48,16 @@ download $(SRCDIR):
        git submodule foreach 'git pull --ff-only origin master'
 
 .PHONY: upload
+upload: UPLOAD_DIST ?= $(DEB_DISTRIBUTION)
 upload: $(DEB)
-       tar cf - $(DEB)|ssh -X repoman@repo.proxmox.com -- upload --product pmg,pve --dist bullseye
+       tar cf - $(DEB)|ssh -X repoman@repo.proxmox.com -- upload --product pmg,pve --dist $(UPLOAD_DIST)
 
 .PHONY: distclean
 distclean: clean
 
 .PHONY: clean
 clean:
-       rm -rf *~ debian/*~ *.deb $(BUILDDIR) *.changes *.dsc *.buildinfo $(PACKAGE)*.tar.gz
+       rm -rf $(PACKAGE)-[0-9]*/ $() *.deb *.dsc $(PACKAGE)*.tar.[gx]z *.changes *.dsc *.buildinfo *.build
 
 .PHONY: dinstall
 dinstall: deb