X-Git-Url: https://git.proxmox.com/?a=blobdiff_plain;f=Makefile;h=78528af8418c099fb5e6161b76fcf8518de53e61;hb=eec9f9fe007546123ebc87b6489abe1dd2cbad17;hp=2e3d4e1ac0eaf874b49d8f9f51986b37a8080aaf;hpb=4478c2ae2ff38cb161f2ad6fc09c100512676439;p=qemu-server.git diff --git a/Makefile b/Makefile index 2e3d4e1a..78528af8 100644 --- a/Makefile +++ b/Makefile @@ -2,6 +2,7 @@ include /usr/share/dpkg/pkg-info.mk include /usr/share/dpkg/architecture.mk PACKAGE=qemu-server +BUILDDIR ?= ${PACKAGE}-${DEB_VERSION_UPSTREAM} DESTDIR= PREFIX=/usr @@ -20,6 +21,7 @@ GITVERSION:=$(shell git rev-parse HEAD) DEB=${PACKAGE}_${DEB_VERSION_UPSTREAM_REVISION}_${DEB_BUILD_ARCH}.deb DBG_DEB=${PACKAGE}-dbgsym_${DEB_VERSION_UPSTREAM_REVISION}_${DEB_BUILD_ARCH}.deb +DSC=${PACKAGE}_${DEB_VERSION_UPSTREAM_REVISION}.dsc DEBS=${DEB} ${DBG_DEB} @@ -50,7 +52,7 @@ qmrestore.zsh-completion: mv $@.tmp $@ PKGSOURCES=qm qm.1 qmrestore qmrestore.1 qmextract qm.conf.5 qm.bash-completion qmrestore.bash-completion \ - qm.zsh-completion qmrestore.zsh-completion + qm.zsh-completion qmrestore.zsh-completion cpu-models.conf.5 .PHONY: install install: ${PKGSOURCES} @@ -74,19 +76,28 @@ install: ${PKGSOURCES} install -m 0755 qmextract ${DESTDIR}${LIBDIR} install -m 0644 qm.1 ${DESTDIR}/${MAN1DIR} install -m 0644 qmrestore.1 ${DESTDIR}/${MAN1DIR} + install -m 0644 cpu-models.conf.5 ${DESTDIR}/${MAN5DIR} install -m 0644 qm.conf.5 ${DESTDIR}/${MAN5DIR} cd ${DESTDIR}/${MAN5DIR}; ln -s -f qm.conf.5.gz vm.conf.5.gz +${BUILDDIR}: + rm -rf $(BUILDDIR) + rsync -a * $(BUILDDIR) + echo "git clone git://git.proxmox.com/git/qemu-server.git\\ngit checkout $(GITVERSION)" > $(BUILDDIR)/debian/SOURCE + .PHONY: deb deb: ${DEBS} ${DBG_DEB}: ${DEB} -${DEB}: - rm -rf build - rsync -a * build - echo "git clone git://git.proxmox.com/git/qemu-server.git\\ngit checkout ${GITVERSION}" > build/debian/SOURCE - cd build; dpkg-buildpackage -b -us -uc +${DEB}: $(BUILDDIR) + cd $(BUILDDIR); dpkg-buildpackage -b -us -uc lintian ${DEBS} +.PHONY: dsc +dsc: ${DSC} +${DSC}: ${BUILDDIR} + cd ${BUILDDIR}; dpkg-buildpackage -S -us -uc -d + lintian ${DSC} + .PHONY: test test: PVE_GENERATING_DOCS=1 perl -I. ./qm verifyapi @@ -94,12 +105,13 @@ test: .PHONY: upload upload: ${DEB} - tar cf - ${DEBS} | ssh repoman@repo.proxmox.com upload --product pve --dist buster + tar cf - ${DEBS} | ssh -X repoman@repo.proxmox.com upload --product pve --dist bullseye .PHONY: clean clean: + $(MAKE) -C test $@ + rm -rf $(PACKAGE)-*/ *.deb *.buildinfo *.changes *.dsc $(PACKAGE)_*.tar.gz $(MAKE) cleanup-docgen - rm -rf build *.deb *.buildinfo *.changes find . -name '*~' -exec rm {} ';'