]> git.proxmox.com Git - ifupdown2.git/blame - Makefile
bump version to 3.2.0-1+pmx8
[ifupdown2.git] / Makefile
CommitLineData
1d5643c4
TL
1include /usr/share/dpkg/pkg-info.mk
2
51419183 3PACKAGE=ifupdown2
51419183
AD
4
5SRCDIR=ifupdown2
4fb10245 6BUILDDIR=$(SRCDIR)-$(DEB_VERSION)
51419183 7
51419183
AD
8GITVERSION:=$(shell git rev-parse HEAD)
9
e668a427
TL
10ORIG_SRC_TAR=$(PACKAGE)_$(DEB_VERSION_UPSTREAM).orig.tar.gz
11DSC=$(PACKAGE)_$(DEB_VERSION).dsc
4fb10245 12DEB=$(PACKAGE)_$(DEB_VERSION)_all.deb
51419183 13
6e7ad15f
TL
14all: $(DEB)
15 @echo $(DEB)
51419183
AD
16
17.PHONY: submodule
18submodule:
6e7ad15f 19 test -f "$(SRCDIR)/debian/changelog" || git submodule update --init
51419183 20
6e7ad15f
TL
21buildir: $(BUILDDIR)
22$(BUILDDIR): submodule
c4159c1c
TL
23 rm -rf $@ $@.tmp
24 cp -a $(SRCDIR)/ $@.tmp/
25 rm -rf $@.tmp/debian
26 cp -a debian $@.tmp/
27 mv $@.tmp $@
08415f37 28
e668a427 29.PHONY: deb dsc
6e7ad15f
TL
30deb: $(DEB)
31$(DEB): $(BUILDDIR)
e668a427
TL
32 cd $(BUILDDIR); dpkg-buildpackage -b -uc -us
33
34$(ORIG_SRC_TAR): $(BUILDDIR)
35 tar czf $(ORIG_SRC_TAR) --exclude="$(BUILDDIR)/debian" $(BUILDDIR)
36
37dsc: $(DSC)
38$(DSC): $(BUILDDIR) $(ORIG_SRC_TAR)
39 cd $(BUILDDIR); dpkg-buildpackage -S -uc -us -d
51419183 40
3a7603f0
TL
41sbuild: $(DSC)
42 sbuild $(DSC)
43
51419183 44.PHONY: upload
a5071898 45upload: UPLOAD_DIST ?= $(DEB_DISTRIBUTION)
6e7ad15f 46upload: $(DEB)
a5071898 47 tar cf - $(DEB) | ssh -X repoman@repo.proxmox.com -- upload --product pve,pmg,pbs --dist $(UPLOAD_DIST)
51419183 48
6e7ad15f 49.PHONY: distclean clean
51419183 50distclean: clean
51419183 51clean:
e668a427 52 rm -rf $(PACKAGE)-*/ *.deb *.dsc *.changes *.buildinfo *.build $(PACKAGE)*.tar.*
51419183
AD
53
54.PHONY: dinstall
55dinstall: deb
6e7ad15f 56 dpkg -i $(DEB)