summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2004-04-14 13:00:22 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:51:17 -0500
commitbfbe809a6f9543599af0177ca954d49865166f9e (patch)
treec4d18039b2379f6dd7daa91b9b5ad4cfe3e74f5b
parent3b2993cf0dbcb7167363fb47ed7dba99aa55a00a (diff)
downloadsamba-bfbe809a6f9543599af0177ca954d49865166f9e.tar.gz
samba-bfbe809a6f9543599af0177ca954d49865166f9e.tar.bz2
samba-bfbe809a6f9543599af0177ca954d49865166f9e.zip
r211: svk has different revision numbers,
so use "3.9.0-SVK-build-276-metze@dragon" as version when the working copy is checked out with svk metze (This used to be commit a99e31d10fefa6f0bc12444cfc97e5398e80e518)
-rwxr-xr-xsource4/script/mkversion.sh21
1 files changed, 14 insertions, 7 deletions
diff --git a/source4/script/mkversion.sh b/source4/script/mkversion.sh
index f3d385e27e..69b24a137b 100755
--- a/source4/script/mkversion.sh
+++ b/source4/script/mkversion.sh
@@ -51,15 +51,22 @@ fi
if test x"${SAMBA_VERSION_IS_SVN_SNAPSHOT}" = x"yes";then
- TMP_SVN_REVISION=`(svn info ${SOURCE_DIR} 2>/dev/null || svk info ${SOURCE_DIR} 2>/dev/null) |grep Revision: |sed -e 's/Revision: \([0-9]*\).*/\1/'`
- TMP_SVN_REVISION_STR=""
- if test -n "${TMP_SVN_REVISION}";then
- TMP_SVN_REVISION_STR="-${TMP_SVN_REVISION}"
+ HAVESVN=yes
+ TMP_SVN_REVISION=`(svn info ${SOURCE_DIR} 2>/dev/null || HAVESVN=no) |grep Revision: |sed -e 's/Revision: \([0-9]*\).*/\1/'`
+ if test x"${HAVESVN}" = x"no";then
+ HAVESVK=yes
+ TMP_SVK_REVISION=`(svk info ${SOURCE_DIR} 2>/dev/null || HAVESVK=no) |grep Revision: |sed -e 's/Revision: \([0-9]*\).*/\1/'`
+ TMP_SVK_REVISION_STR="${TMP_SVK_REVISION}-${USER}@${HOSTNAME}"
+ fi
+
+ if test x"${HAVESVN}" = x"yes";then
+ SAMBA_VERSION_STRING="${SAMBA_VERSION_STRING}-SVN-build-${TMP_SVN_REVISION}"
+ echo "#define SAMBA_VERSION_SVN_REVISION ${TMP_SVN_REVISION}" >> $OUTPUT_FILE
+ elif test x"${HAVESVK}" = x"yes";then
+ SAMBA_VERSION_STRING="${SAMBA_VERSION_STRING}-SVK-build-${TMP_SVK_REVISION_STR}"
else
- TMP_SVN_REVISION=0
+ SAMBA_VERSION_STRING="${SAMBA_VERSION_STRING}-SVN-build-UNKNOWN"
fi
- SAMBA_VERSION_STRING="${SAMBA_VERSION_STRING}-SVN-build${TMP_SVN_REVISION_STR}"
- echo "#define SAMBA_VERSION_SVN_REVISION ${TMP_SVN_REVISION}" >> $OUTPUT_FILE
fi
if test -n "${SAMBA_VERSION_VENDOR_SUFFIX}";then