]> git.proxmox.com Git - pve-ha-manager.git/blame_incremental - Makefile
Tools/Config: refactor lrm status json reading
[pve-ha-manager.git] / Makefile
... / ...
CommitLineData
1VERSION=2.0
2PACKAGE=pve-ha-manager
3SIMPACKAGE=pve-ha-simulator
4PKGREL=5
5
6GITVERSION:=$(shell git rev-parse HEAD)
7
8ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH)
9
10DEB=${PACKAGE}_${VERSION}-${PKGREL}_${ARCH}.deb
11SIMDEB=${SIMPACKAGE}_${VERSION}-${PKGREL}_all.deb
12
13
14all: deb
15
16.PHONY: dinstall
17dinstall: $(DEB) $(SIMDEB)
18 dpkg -i ${DEB} ${SIMDEB}
19
20
21.PHONY: simdeb
22simdeb: ${SIMDEB}
23${SIMDEB}:
24 rm -rf build
25 mkdir build
26 rsync -a src/ build
27 rsync -a simdebian/ build/debian
28 cp changelog.Debian build/debian/changelog
29 echo "git clone git://git.proxmox.com/git/pve-ha-manager.git\\ngit checkout ${GITVERSION}" > build/debian/SOURCE
30 cd build; dpkg-buildpackage -rfakeroot -b -us -uc
31 lintian ${SIMDEB}
32
33.PHONY: deb
34deb: ${DEB} ${SIMDEB}
35${DEB}:
36 rm -rf build
37 mkdir build
38 rsync -a src/ build
39 rsync -a debian/ build/debian
40 cp changelog.Debian build/debian/changelog
41 echo "git clone git://git.proxmox.com/git/pve-ha-manager.git\\ngit checkout ${GITVERSION}" > build/debian/SOURCE
42 cd build; dpkg-buildpackage -rfakeroot -b -us -uc
43 lintian ${DEB}
44
45.PHONY: clean
46clean:
47 make -C src clean
48 rm -rf build *.deb ${PACKAGE}-*.tar.gz *.changes *.buildinfo
49 find . -name '*~' -exec rm {} ';'
50
51.PHONY: distclean
52distclean: clean
53
54.PHONY: upload
55upload: ${DEB} ${SIMDEB}
56 tar cf - ${DEB} ${SIMDEB}|ssh repoman@repo.proxmox.com -- upload --product pve --dist stretch --arch ${ARCH}
57