Guenter Roeck ([email protected]) just uploaded a new patch set to gerrit, 
which you can find at http://review.coreboot.org/1151

-gerrit

commit 5ca8014b8aa506b31dca23c5c3291d4b20bb0bd9
Author: Guenter Roeck <[email protected]>
Date:   Fri Jun 29 12:25:46 2012 -0700

    superiotool: Add support for git-based version number
    
    The superiotool Makefile extracts a version number from SVN. This does not 
work
    well with a git repository, and results in an empty version number. Expand 
it to
    use the git version number (using git describe) if the repository is not a 
svn
    repository.
    
    Change-Id: Idf92c02753b28ef5bcdd3b6df4a08d79ae974434
    Signed-off-by: Guenter Roeck <[email protected]>
---
 util/superiotool/Makefile |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/util/superiotool/Makefile b/util/superiotool/Makefile
index e7d2f63..e141638 100644
--- a/util/superiotool/Makefile
+++ b/util/superiotool/Makefile
@@ -26,8 +26,13 @@ PREFIX  = /usr/local
 
 # Set the superiotool version string from the highest revision number
 # of the checked out superiotool files.
+
+ifneq ($(shell svnversion -cn .), exported)
 SVNDEF := -D'SUPERIOTOOL_VERSION="$(shell svnversion -cn . \
-          | sed -e "s/.*://" -e "s/\([0-9]*\).*/\1/")"'
+       | sed -e "s/.*://" -e "s/\([0-9]*\).*/\1/")"'
+else
+SVNDEF := -D'SUPERIOTOOL_VERSION="$(shell git describe 2>/dev/null)"'
+endif
 
 CFLAGS += -O2 -Wall -Wstrict-prototypes -Wundef -Wstrict-aliasing \
          -Werror-implicit-function-declaration -ansi -pedantic $(SVNDEF)

-- 
coreboot mailing list: [email protected]
http://www.coreboot.org/mailman/listinfo/coreboot

Reply via email to