summaryrefslogtreecommitdiff
path: root/source4/script/mkrelease.sh
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2008-10-21 14:51:13 +0200
committerJelmer Vernooij <jelmer@samba.org>2008-10-21 14:51:13 +0200
commit5209a846a9157e649fcdcb561f7eaf19c8c0e465 (patch)
treeb0a7e52b5646c8eec182dbc391e7934b6804488c /source4/script/mkrelease.sh
parent625359b2e266105022309df8985720108ecd6f67 (diff)
parent2ee8d29d22bcb1c350ab59d71b0aee548489bc9c (diff)
downloadsamba-5209a846a9157e649fcdcb561f7eaf19c8c0e465.tar.gz
samba-5209a846a9157e649fcdcb561f7eaf19c8c0e465.tar.bz2
samba-5209a846a9157e649fcdcb561f7eaf19c8c0e465.zip
Merge branch 'master' of ssh://git.samba.org/data/git/samba into regsrv
Conflicts: source4/lib/registry/ldb.c source4/rpc_server/winreg/rpc_winreg.c
Diffstat (limited to 'source4/script/mkrelease.sh')
-rwxr-xr-xsource4/script/mkrelease.sh16
1 files changed, 13 insertions, 3 deletions
diff --git a/source4/script/mkrelease.sh b/source4/script/mkrelease.sh
index 0af738deb5..6a8c5ae2e7 100755
--- a/source4/script/mkrelease.sh
+++ b/source4/script/mkrelease.sh
@@ -1,6 +1,6 @@
#!/bin/sh
-if [ ! -d ".git" -o `dirname $0` != "./source/script" ]; then
+if [ ! -d ".git" -o `dirname $0` != "./source4/script" ]; then
echo "Run this script from the top-level directory in the"
echo "repository as: ./source/script/mkrelease.sh"
exit 1
@@ -9,13 +9,23 @@ fi
TMPDIR=`mktemp -d samba-XXXXX`
(git archive --format=tar HEAD | (cd $TMPDIR/ && tar xf -))
-( cd $TMPDIR/source || exit 1
+#Prepare the tarball for a Samba4 release, with some generated files,
+#but without Samba3 stuff (to avoid confusion)
+( cd $TMPDIR/ || exit 1
+ rm -rf source3 packaging docs-xml examples swat WHATSNEW.txt MAINTAINERS || exit 1
+ cd source4 || exit 1
./autogen.sh || exit 1
./configure || exit 1
make dist || exit 1
) || exit 1
-VERSION=`sed -n 's/^SAMBA_VERSION_STRING=//p' $TMPDIR/source/version.h`
+VERSION_FILE=$TMPDIR/source4/version.h
+if [ ! -f $VERSION_FILE ]; then
+ echo "Cannot find version.h at $VERSION_FILE"
+ exit 1;
+fi
+
+VERSION=`sed -n 's/^SAMBA_VERSION_STRING=//p' $VERSION_FILE`
mv $TMPDIR samba-$VERSION || exit 1
tar -cf samba-$VERSION.tar samba-$VERSION || (rm -rf samba-$VERSION; exit 1)
rm -rf samba-$VERSION || exit 1