diff options
| author | Adam <Adam@anope.org> | 2010-12-24 20:05:52 -0500 |
|---|---|---|
| committer | Adam <Adam@anope.org> | 2010-12-24 20:05:52 -0500 |
| commit | faf1e3710ef2d86c6b4a562814d6cfaa064723a9 (patch) | |
| tree | 5e5aec2de28769d456fe2f0982cc2317407cf478 /Config | |
| parent | e54cffd9b78f5c55a6a68671a811d2f9577ae846 (diff) | |
Fixed version.cpp to work ok if we are on a tag, and
prevent version.cpp from prepending version.sh's VERSION_EXTRA on every build
Diffstat (limited to 'Config')
| -rwxr-xr-x | Config | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -168,11 +168,11 @@ if [ ! "$NO_INTRO" ] ; then VERSION=`git describe --tags` VERSION_BUILD=`echo "$VERSION" | cut -d'-' -f2` VERSION_EXTRA=`echo "$VERSION" | cut -d'-' -f3` - if [ "$VERSION_BUILD" == "$VERSION_EXTRA" ] ; then - VERSION_EXTRA="" + # Only do this if we are not on a tag, src/version.sh will be all we need then. + if [ "$VERSION_BUILD" != "$VERSION_EXTRA" ] ; then + echo "#define VERSION_BUILD $VERSION_BUILD" > include/version.h + echo "#define VERSION_EXTRA \"-$VERSION_EXTRA\"" >> include/version.h fi - echo "#define VERSION_BUILD $VERSION_BUILD" > include/version.h - echo "#define VERSION_EXTRA \"$VERSION_EXTRA\"" >> include/version.h fi cat $SOURCE_DIR/.BANNER | sed "s/CURVER/$VERSION/" | sed "s@SOURCE_DIR@$SOURCE_DIR@" | $PAGER echo "" |
