diff options
author | Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> | 2009-08-31 16:25:08 +0000 |
---|---|---|
committer | Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> | 2009-08-31 16:25:08 +0000 |
commit | 48e5e09cf7644fc8508b3188fb90a4e0172d05c8 (patch) | |
tree | e08b6c49650301785392cb8a3ed0893b74165c97 /Makefile | |
parent | 4dd5e080a1a229cdaa79d80850caa3e192fc84f0 (diff) | |
download | flashrom-48e5e09cf7644fc8508b3188fb90a4e0172d05c8.tar.gz flashrom-48e5e09cf7644fc8508b3188fb90a4e0172d05c8.tar.bz2 flashrom-48e5e09cf7644fc8508b3188fb90a4e0172d05c8.zip |
Add the possibility to set the release name directly as makefile parameter
With this patch, make tarball and make export still work as expected,
but if you specify RELEASENAME=foo, then the directories and tarballs
are named flashrom-foo instead of flashrom-0.9.0-r703. This makes
release creation a lot easier. As an example, look at creating the 0.9.1
tarball: # make tarball RELEASENAME=0.9.1
Corresponding to flashrom svn r704.
Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Acked-by: Stefan Reinauer <stepan@coresystems.de>
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 20 |
1 files changed, 11 insertions, 9 deletions
@@ -60,7 +60,9 @@ all: pciutils features dep $(PROGRAM) # will not require subversion. The downloadable snapshots are already exported. SVNVERSION := $(shell LC_ALL=C svnversion -cn . | sed -e "s/.*://" -e "s/\([0-9]*\).*/\1/" | grep "[0-9]" || echo unknown) -VERSION := 0.9.0-r$(SVNVERSION) +RELEASE := 0.9.0 +VERSION := $(RELEASE)-r$(SVNVERSION) +RELEASENAME ?= $(VERSION) SVNDEF := -D'FLASHROM_VERSION="$(VERSION)"' @@ -146,16 +148,16 @@ install: $(PROGRAM) $(INSTALL) -m 0644 $(PROGRAM).8 $(DESTDIR)$(MANDIR)/man8 export: - @rm -rf $(EXPORTDIR)/flashrom-$(VERSION) - @svn export -r BASE . $(EXPORTDIR)/flashrom-$(VERSION) - @sed "s/^SVNVERSION.*/SVNVERSION := $(SVNVERSION)/" Makefile >$(EXPORTDIR)/flashrom-$(VERSION)/Makefile - @LC_ALL=C svn log >$(EXPORTDIR)/flashrom-$(VERSION)/ChangeLog - @echo Exported $(EXPORTDIR)/flashrom-$(VERSION)/ + @rm -rf $(EXPORTDIR)/flashrom-$(RELEASENAME) + @svn export -r BASE . $(EXPORTDIR)/flashrom-$(RELEASENAME) + @sed "s/^SVNVERSION.*/SVNVERSION := $(SVNVERSION)/" Makefile >$(EXPORTDIR)/flashrom-$(RELEASENAME)/Makefile + @LC_ALL=C svn log >$(EXPORTDIR)/flashrom-$(RELEASENAME)/ChangeLog + @echo Exported $(EXPORTDIR)/flashrom-$(RELEASENAME)/ tarball: export - @tar cjf $(EXPORTDIR)/flashrom-$(VERSION).tar.bz2 -C $(EXPORTDIR)/ $(TAROPTIONS) flashrom-$(VERSION)/ - @rm -rf $(EXPORTDIR)/flashrom-$(VERSION) - @echo Created $(EXPORTDIR)/flashrom-$(VERSION).tar.bz2 + @tar cjf $(EXPORTDIR)/flashrom-$(RELEASENAME).tar.bz2 -C $(EXPORTDIR)/ $(TAROPTIONS) flashrom-$(RELEASENAME)/ + @rm -rf $(EXPORTDIR)/flashrom-$(RELEASENAME) + @echo Created $(EXPORTDIR)/flashrom-$(RELEASENAME).tar.bz2 .PHONY: all clean distclean dep compiler pciutils features export tarball |