Makefile: Add local-srpm target to create a .src.rpm from HEAD

This commit is contained in:
Brian C. Lane 2021-06-29 15:45:59 -07:00
parent 5dfa95d769
commit 3f04cf9b59

View File

@ -104,6 +104,12 @@ local:
@rm -rf /var/tmp/$(PKGNAME)-$(VERSION) @rm -rf /var/tmp/$(PKGNAME)-$(VERSION)
@echo "The archive is in $(PKGNAME)-$(VERSION).tar.gz" @echo "The archive is in $(PKGNAME)-$(VERSION).tar.gz"
local-srpm: local $(PKGNAME).spec
rpmbuild -bs \
--define "_sourcedir $(CURDIR)" \
--define "_srcrpmdir $(CURDIR)" \
lorax.spec
test-in-copy: test-in-copy:
rsync -a --exclude=.git /lorax-ro/ /lorax/ rsync -a --exclude=.git /lorax-ro/ /lorax/
make -C /lorax/ $(RUN_TESTS) make -C /lorax/ $(RUN_TESTS)