]> git.proxmox.com Git - pve-ha-manager.git/blame - Makefile
buildsys: use full DEB_VERSION and correct DEB_HOST_ARCH
[pve-ha-manager.git] / Makefile
CommitLineData
e72075d0
TL
1include /usr/share/dpkg/pkg-info.mk
2include /usr/share/dpkg/architecture.mk
3
6cbcb5f7 4PACKAGE=pve-ha-manager
c0a900cc 5SIMPACKAGE=pve-ha-simulator
3a1c66d6 6
9cdf16b1 7GITVERSION:=$(shell git rev-parse HEAD)
df0c583f 8BUILDDIR ?= $(PACKAGE)-$(DEB_VERSION)
6cbcb5f7 9
df0c583f
TL
10DEB=$(PACKAGE)_$(DEB_VERSION)_$(DEB_HOST_ARCH).deb
11DBG_DEB=$(PACKAGE)-dbgsym_$(DEB_VERSION)_$(DEB_HOST_ARCH).deb
fe3781e8 12
df0c583f
TL
13DSC=$(PACKAGE)_$(DEB_VERSION).dsc
14SIMDEB=$(SIMPACKAGE)_$(DEB_VERSION)_all.deb
15SIMDSC=$(SIMPACKAGE)_$(DEB_VERSION).dsc
6cbcb5f7 16
5ff407da 17all: deb
6cbcb5f7 18
69e37516
TL
19$(BUILDDIR):
20 rm -rf $(BUILDDIR)
21 rsync -a src/ debian $(BUILDDIR)
22 echo "git clone git://git.proxmox.com/git/pve-ha-manager.git\\ngit checkout $(GITVERSION)" > $(BUILDDIR)/debian/SOURCE
f9362515 23
745fd425 24.PHONY: dinstall
fea8212c 25dinstall: $(DEB) $(SIMDEB)
69e37516 26 dpkg -i $(DEB) $(SIMDEB)
6cbcb5f7 27
fea8212c 28.PHONY: deb
69e37516
TL
29deb: $(DEB) $(SIMDEB)
30$(DEB) $(DBG_DEB): $(BUILDDIR)
31 cd $(BUILDDIR); dpkg-buildpackage -b -us -uc
32 lintian $(DEB)
33 lintian $(SIMDEB)
3a1c66d6 34
f9362515 35.PHONY: dsc
69e37516
TL
36dsc: $(DSC)
37$(DSC): $(BUILDDIR)
38 cd $(BUILDDIR); dpkg-buildpackage -S -us -uc -d
39 lintian $(DSC)
f9362515 40
f501f7e3 41.PHONY: clean
ba878e35 42clean:
8cb12b9e 43 make -C src clean
69e37516 44 rm -rf $(BUILDDIR) *.tar.gz *.dsc *.deb $(PACKAGE)-*.tar.gz *.changes *.buildinfo
6cbcb5f7
DM
45
46.PHONY: distclean
47distclean: clean
f501f7e3 48
952a637d 49.PHONY: upload
69e37516 50upload: $(DEB) $(SIMDEB)
df0c583f 51 tar cf - $(DEB) $(DBG_DEB) $(SIMDEB)|ssh repoman@repo.proxmox.com -- upload --product pve --dist bullseye --arch $(DEB_HOST_ARCH)
952a637d 52