"make gitrpm" creates an rpm from the last git checkin "make rpm" creates an rpm for the version tagged with $VERSION "make dist" creates a tarball for the version tagged with $VERSION --- Makefile | 12 +++++++++++- 1 files changed, 11 insertions(+), 1 deletions(-) diff --git a/Makefile b/Makefile index e70f309..ae4a9d4 100644 --- a/Makefile +++ b/Makefile @@ -37,10 +37,20 @@ clean: archive: dracut-$(VERSION)-$(GITVERSION).tar.bz2 +dist: dracut-$(VERSION).tar.bz2 + +dracut-$(VERSION).tar.bz2: + git archive --format=tar $(VERSION) --prefix=dracut-$(VERSION)/ |bzip2 > dracut-$(VERSION).tar.bz2 + dracut-$(VERSION)-$(GITVERSION).tar.bz2: git archive --format=tar HEAD --prefix=dracut-$(VERSION)-$(GITVERSION)/ |bzip2 > dracut-$(VERSION)-$(GITVERSION).tar.bz2 -rpm: dracut-$(VERSION)-$(GITVERSION).tar.bz2 + +rpm: dracut-$(VERSION).tar.bz2 + rpmbuild --define "_topdir $$PWD" --define "_sourcedir $$PWD" --define "_specdir $$PWD" --define "_srcrpmdir $$PWD" --define "_rpmdir $$PWD" -ba dracut.spec + rm -fr BUILD BUILDROOT + +gitrpm: dracut-$(VERSION)-$(GITVERSION).tar.bz2 rpmbuild --define "_topdir $$PWD" --define "_sourcedir $$PWD" --define "_specdir $$PWD" --define "_srcrpmdir $$PWD" --define "_rpmdir $$PWD" --define "gittag $(GITVERSION)" -ba dracut.spec rm -fr BUILD BUILDROOT -- 1.6.2.2 -- To unsubscribe from this list: send the line "unsubscribe initramfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html