]> git.proxmox.com Git - spiceterm.git/blob - Makefile
build: fix -dbgsym generation
[spiceterm.git] / Makefile
1 include /usr/share/dpkg/pkg-info.mk
2 include /usr/share/dpkg/architecture.mk
3
4 PACKAGE=spiceterm
5
6 GITVERSION:=$(shell cat .git/refs/heads/master)
7 BUILDDIR ?= ${PACKAGE}-${DEB_VERSION_UPSTREAM}
8
9 export VERSION=$(DEB_VERSION_UPSTREAM)
10
11 DEB=${PACKAGE}_${DEB_VERSION_UPSTREAM_REVISION}_${DEB_BUILD_ARCH}.deb
12 DBG_DEB=${PACKAGE}-dbgsym_${DEB_VERSION_UPSTREAM_REVISION}_${DEB_BUILD_ARCH}.deb
13 DSC=${PACKAGE}_${DEB_VERSION_UPSTREAM_REVISION}.dsc
14
15 ${BUILDDIR}: src/ debian/
16 rm -rf $(BUILDDIR)
17 rsync -a src/ debian $(BUILDDIR)
18 echo "git clone git://git.proxmox.com/git/spiceterm.git\\ngit checkout ${GITVERSION}" > $(BUILDDIR)/debian/SOURCE
19
20 .PHONY: dsc
21 dsc: ${DSC}
22 ${DSC}: $(BUILDDIR)
23 cd $(BUILDDIR); dpkg-buildpackage -S -us -uc -d
24 lintian ${DSC}
25
26 .PHONY: deb
27 deb: ${DEB}
28 ${DEB}: $(BUILDDIR)
29 cd $(BUILDDIR); dpkg-buildpackage -b -us -uc
30 lintian ${DEB}
31
32 .PHONY: dinstall
33 dinstall: ${DEB}
34 dpkg -i ${DEB}
35
36 .PHONY: upload
37 upload: ${DEB}
38 tar cf - ${DEB} ${DBG_DEB} | ssh repoman@repo.proxmox.com -- upload --product pve --dist bullseye --arch ${ARCH}
39
40 .PHONY: distclean clean
41 distclean: clean
42 clean:
43 rm -rf *~ $(PACKAGE)-*/ *.deb *.changes genfont *.buildinfo *.dsc *.tar.gz