summaryrefslogtreecommitdiff
path: root/config/gr_git.m4
diff options
context:
space:
mode:
authorJohnathan Corgan2010-06-02 16:42:26 -0700
committerJohnathan Corgan2010-06-02 16:42:26 -0700
commitba0a21798e0d59ac54454908e4dabeac5783f731 (patch)
treee8050e420483d7730c9273c91cbbd4a09c250030 /config/gr_git.m4
parent483681462b8138f048746502b72982d8bc5730b0 (diff)
parentb3bd2c61d615ba01f1fb97819461b057190e1632 (diff)
downloadgnuradio-ba0a21798e0d59ac54454908e4dabeac5783f731.tar.gz
gnuradio-ba0a21798e0d59ac54454908e4dabeac5783f731.tar.bz2
gnuradio-ba0a21798e0d59ac54454908e4dabeac5783f731.zip
Merge branch 'master' into next
* master: gcell: make versioned libraries gnuradio-core: fix missing linker flags for boost_program_options howto: fix incorrect include path build: redo GR_GIT for portability build: use date format string instead of -R for portability gnuradio-core: fix typo in doxygen header gr-qtgui: add include file for gcc 4.4.1
Diffstat (limited to 'config/gr_git.m4')
-rw-r--r--config/gr_git.m423
1 files changed, 14 insertions, 9 deletions
diff --git a/config/gr_git.m4 b/config/gr_git.m4
index 5e8aa663b..c4f1ea0c0 100644
--- a/config/gr_git.m4
+++ b/config/gr_git.m4
@@ -30,18 +30,23 @@ AC_DEFUN([GR_GIT],[
AC_MSG_CHECKING([git description of current commit])
if (cd $srcdir && $GIT describe >/dev/null 2>&1); then
GIT_DESCRIBE=`cd $srcdir && $GIT describe --abbrev=8 --long`
- GIT_TAG=`echo $GIT_DESCRIBE | cut -f 1 -d '-'`
- GIT_SEQNO=`echo $GIT_DESCRIBE | cut -f 2 -d '-'`
- GIT_COMMIT=`echo $GIT_DESCRIBE | cut -f 3 -d '-' | cut -f 2- -d 'g'`
# Release candidate tags create an extra -rcX field
- if test x`echo $GIT_DESCRIBE | cut -f 1- -d '-' --output-delimiter=' ' | wc -w` = x4; then
- GIT_TAG=`echo $GIT_DESCRIBE | cut -f -2 -d '-'`
- GIT_SEQNO=`echo $GIT_DESCRIBE | cut -f 3 -d '-'`
- GIT_COMMIT=`echo $GIT_DESCRIBE | cut -f 4 -d '-' | cut -f 2- -d 'g'`
- fi
+ case $GIT_DESCRIBE in
+ *-*-*-*)
+ GIT_TAG=`echo $GIT_DESCRIBE | cut -f -2 -d '-'`
+ GIT_SEQNO=`echo $GIT_DESCRIBE | cut -f 3 -d '-'`
+ GIT_COMMIT=`echo $GIT_DESCRIBE | cut -f 4 -d '-' | cut -f 2- -d 'g'`
+ ;;
+ *-*-*)
+ GIT_TAG=`echo $GIT_DESCRIBE | cut -f 1 -d '-'`
+ GIT_SEQNO=`echo $GIT_DESCRIBE | cut -f 2 -d '-'`
+ GIT_COMMIT=`echo $GIT_DESCRIBE | cut -f 3 -d '-' | cut -f 2- -d 'g'`
+ ;;
+ esac
+
AC_MSG_RESULT([$GIT_DESCRIBE])
else
- AC_MSG_RESULT([unable to find, using current commit])
+ AC_MSG_RESULT([no tag in history, using current commit])
GIT_TAG=''
GIT_SEQNO=''
GIT_COMMIT=`cd $srcdir && $GIT describe --always --abbrev=8`