summaryrefslogtreecommitdiffstats
path: root/release
diff options
context:
space:
mode:
Diffstat (limited to 'release')
-rw-r--r--release/KOffice-HOWTO105
-rw-r--r--release/RELEASE-CHECKLIST80
-rwxr-xr-xrelease/anon3
-rwxr-xr-xrelease/checkout30
-rwxr-xr-xrelease/checkxml13
-rwxr-xr-xrelease/common47
-rwxr-xr-xrelease/compile_all63
-rw-r--r--release/config.options1
-rwxr-xr-xrelease/create_all_changelogs8
-rw-r--r--release/create_sources_inc32
-rwxr-xr-xrelease/difftarball15
-rwxr-xr-xrelease/dist18
-rwxr-xr-xrelease/docu38
-rwxr-xr-xrelease/dosnapshot64
-rwxr-xr-xrelease/koffice-l10n132
-rw-r--r--release/language_list71
-rw-r--r--release/modules20
-rwxr-xr-xrelease/pack60
-rwxr-xr-xrelease/pack_all1
-rwxr-xr-xrelease/removestuff118
-rw-r--r--release/select-l10n33
-rw-r--r--release/snapmodules46
-rw-r--r--release/svn2log.py322
-rwxr-xr-xrelease/tag_all108
-rwxr-xr-xrelease/taritup76
-rw-r--r--release/versions31
-rwxr-xr-xrelease/xdelta35
27 files changed, 1570 insertions, 0 deletions
diff --git a/release/KOffice-HOWTO b/release/KOffice-HOWTO
new file mode 100644
index 0000000..b805e58
--- /dev/null
+++ b/release/KOffice-HOWTO
@@ -0,0 +1,105 @@
+KOffice tagging HOWTO.
+----------------------
+
+* OVERVIEW
+
+Recently, we've had two people preparing KOffice releases: one tagging
+trunk or the branch, the other tagging the l10n files. The former is
+done using the tag_all script, see 'TAGGING TRUNK/BRANCHES' below.
+The latter is done using the koffice-l10n script, which can be used to
+tag koffice-l10n without downloading the entire l10n tree. This is
+described in TAGGING L10N below.
+
+Things to look out for:
+
+The tag_all script will create the tags/koffice/x.y.z directory, if it
+doesn't exist. So will koffice-l10n. Co-ordinate with anyone else
+tagging to avoid two people doing the `svn mkdir', otherwise you'll
+get conflicts. Particularly, if someone else is doing the l10n tag,
+you should check that they are not already preparing their tag because
+l10n tagging takes longer.
+
+
+
+* TAGGING TRUNK/BRANCHES
+
+1. Get the latest sources with "svn up" and check if builds with
+ unsermake and automake. Also check if it compiles with
+ --enable-final and with builddir!=srcdir.
+
+2. Checkout trunk/KDE/kde-common/release. The files in that directory
+ will support you in creating the tarball.
+
+3. Create directories as per checklist, under the directory that
+ contains the scripts from kde-common/release;
+ cd release
+ mkdir clean sources-old sources dirty test build done
+
+4. Change the version in the "common" file.
+
+5. Change the version of koffice in the "version" script that is
+ called from tag_all;
+ HEADURL=branches/koffice/1.6/koffice
+ DESTURL=tags/koffice/1.5.2/$1
+
+5. Make sure the "modules" file only contains koffice.
+ echo "koffice" > modules
+
+6. Use the "checkout" script to create a KOffice checkout of the
+ named brached in the "clean/koffice" directory.
+ You may need to define (where mysvnusername needs to be replaced
+ with your kde-svn username);
+ export SVNUSER="mysvnusername"
+ export SVNPROTOCOL="https"
+
+7. Update to new version-number, e.g. at
+ configure.in.in
+ koffice/koffice.lsm
+ koffice/configure.in.in
+ lib/kofficecore/kofficeversion.h
+ kexi/kexi_version.h
+ kplato/kptaboutdata.h
+
+8. Run the "fixuifiles" script (from kdesdk).
+ cd clean/koffice
+ find . -type f -name "*.ui" -exec fixuifiles {} ';'
+
+9. Commit all changes.
+
+10. Run the "tag_all" script.
+
+11. Now it's simply a matter of uploading and signing, as per
+ RELEASE_CHECKLIST.
+
+12. Also don't forget to add a new section at bugs.kde.org for the new
+ version.
+
+
+* TAGGING L10N
+
+The instructions for this are at the top of the koffice-l10n script.
+The script avoids downloading the entire l10n tree, but does end up
+making hundreds of connections to the svn server.
+
+It seems it _might_ be a good idea make the script checkout from
+anonsvn first. For this, simply change the line that begins "BASE="
+in the script, then use:
+ svn switch --relocate \
+ svn://anonsvn.kde.org/home/kde/tags/koffice \
+ $SVNPROTOCOL://[email protected]/home/kde/tags/koffice
+
+... after running the script. However, as the script stands, it just
+checkout from svn.kde.org server. The problem with this method is
+that copying the admin directory in scripts doesn't get added to the
+tag. Fix the script, or copy it manually if you use this technique.
+
+Note that `svn switch --relocate' is _very_ slow for what it appears
+to be doing. If you're not convinced it's doing anything, the value
+from the following should be decreasing:
+
+find clean/tags-koffice -type d -a ! -regex .*svn.*| \
+ (xargs -I{} svn info {})|grep ^URL.*anon|wc
+
+If you have problems when running ./pack, you should ensure that you
+have the latest customizations directory from kdelibs/kdoctools in the
+current KDE branch.
diff --git a/release/RELEASE-CHECKLIST b/release/RELEASE-CHECKLIST
new file mode 100644
index 0000000..578eb84
--- /dev/null
+++ b/release/RELEASE-CHECKLIST
@@ -0,0 +1,80 @@
+Make the following directories:
+clean sources-old sources dirty
+and optionally:
+test build done
+
+Choose version number:
+ * remember that RPM is stupid and considers 5.0beta1 newer than
+ 5.0, so always use "code versions" for the packages. Also
+ stuff like "-" etc is not working, so omit it
+
+Checkout branch:
+ fix the paths in versions script
+ use the checkout script
+ clean up the cache/ directory from previous builds
+
+Update version number
+ * */*.lsm
+ * arts/configure.in.in
+ * kdewebdev/quanta/src/quanta.h
+ * kdevelop/configure.in.in
+ * kdebase/konqueror/version.h
+ * kdebase/startkde
+ * kde-common/admin/cvs.sh has VERSION="3.x.x"
+ * kdelibs/kdecore/kdeversion.h
+ * kdelibs/kdecore/ksycoca.h --> ksycoca version number
+ * kdelibs/README
+ * kdenetwork/kopete/libkopete/kopeteversion.h
+ * bugs/template/wizard/report.html.tmpl
+ * bugs/bugz/wizard_config.pl
+ * www/areas/enterprise/bizcase/form.inc (major KDE versions only)
+ * for koffice: configure.in.in, lib/kofficecore/kofficeversion.h, etc.
+ * common and versions scripts
+
+Update kdepackages in kdelibs/kdeui
+Run "fixuifiles"
+Make sure the meinproc in path is a version of the correct branch
+Use tag_all to get clean sources into "clean" directory (e.g. <releasedir>/clean/koffice)
+Make tarballs using "pack <module>". Start with kde-i18n. Do kdelibs/kdebase last.
+If you have to redo a tarball because of a code change and don't want to wait for meinproc to complete,
+ extract the old tarball inside cache/<module> before calling "pack". The docu script will
+ then use the version from the cache instead of regenerating it, saving a lot of time.
+Upload tarballs to their final location, as 'ftprelease' user under a src/ directory.
+chmod o-rwx any new dir (so that they're not yet public)
+chmod g+w the new directory where packagers will put their files
+create contrib/ directory and make it g+w for group "packager"
+Test tarballs
+md5sum *.tar.bz2 kde-i18n/*.tar.bz2 > MD5SUMS
+gpg --detach-sign -a MD5SUMS (if you're bored, do it for all files)
+(Note: for KOffice, MD5SUMS should be signed with --clearsign instead of --detach-sign.)
+Prepare a Changelog
+Inform the packagers (kde-packager at kde dot org)
+Ask for/write announcement (on the kde-promo mailing-list)
+
+When everything is ready:
+
+- Make directory on the FTP site readable, so that mirrors can start getting it
+ Update latest and/or {koffice,kdevelop}-latest symlinks on the FTP site
+
+- clean up the older releases. Make sure that kdestableftp and kdeunstableftp
+ remain in their advertised size limits (~20 GB). Sort out older binary packages,
+ add compatibility links.
+
+- Enable syncing during the night, so that the uplink can be saturated and
+ does not affect interactive server load and network traffic.
+
+- Pre-notify [email protected] and [email protected] about an upcoming release
+ so that they can be ready for fixing bandwidth problems, server outages or similiar.
+ Its not uncommon that slashdotting affects our server structure, and the right
+ people have to know about the release date and time to be able to react in time.
+
+When most of the mirrors behind http://download.kde.org have updated:
+Commit announcement (after adding PHP header/footer)
+Add an entry to www/index.php, www/announcements/index.php, www/info/releases.php,
+www/download/index.php and www/whatiskde/project.php
+
+Post announcement in text to [email protected]
+Post news bit to
+ * dot.kde.org ([email protected])
+ * freshmeat.net
+ * newsgroups, optionally
diff --git a/release/anon b/release/anon
new file mode 100755
index 0000000..7bb0165
--- /dev/null
+++ b/release/anon
@@ -0,0 +1,3 @@
+for f in `find . -type d -name '.svn'`; do
+ rm -rf $f
+done
diff --git a/release/checkout b/release/checkout
new file mode 100755
index 0000000..de35fd3
--- /dev/null
+++ b/release/checkout
@@ -0,0 +1,30 @@
+#!/bin/bash
+# This script tags all modules listed in the "modules" file.
+#
+# Make sure to fix the set_urls function so that it uses the right tags.
+# language_list becomes the subdirs file in the l10n module, make sure it's uptodate.
+# Once it's all done, the script checks out the tagged directories under clean/.
+
+#SVNUSER=coolo
+#SVNPROTOCOL=svn+ssh
+
+test -n "$SVNUSER" || { echo "You must set SVNUSER"; exit 1; }
+test -n "$SVNPROTOCOL" || { echo "You must set SVNPROTOCOL"; exit 1; }
+
+BASE=$SVNPROTOCOL://[email protected]/home/kde
+headrev=`svn log -r HEAD -q $BASE | grep ^r | cut -b2-8 `
+
+. versions
+
+cd clean
+for i in `cat ../modules`; do
+ set_urls $i
+ if test -d $subname; then
+ svn cleanup $subname
+ svn switch $BASE/$HEADURL $subname
+ svn up -r $headrev $subname
+ else
+ svn co -r $headrev $BASE/$HEADURL $subname
+ fi
+done
+
diff --git a/release/checkxml b/release/checkxml
new file mode 100755
index 0000000..50f8a9d
--- /dev/null
+++ b/release/checkxml
@@ -0,0 +1,13 @@
+cd clean/kde-i18n
+find . -name index.docbook | while read file; do
+ cdir=`dirname $file | sed -e "s,.*/kde-i18n,,"`
+ dir=../../cache/kde-i18n/$cdir
+ mkdir -p $dir
+ echo meinproc --check --cache $dir/index.cache.bz2 $file
+ meinproc --check --cache $dir/index.cache.bz2 $file 2>/dev/null || echo "ERROR $file"
+done
+
+find . -name man-*.docbook | while read file; do
+ meinproc --check $file 2>/dev/null || echo "ERROR $file"
+done
+
diff --git a/release/common b/release/common
new file mode 100755
index 0000000..fe1ca4b
--- /dev/null
+++ b/release/common
@@ -0,0 +1,47 @@
+# common script sourced by all others
+
+package=$1
+version=$2
+
+test -n "$package" || { echo "requires modulename as parameter"; exit 1; }
+
+if test -z "$version"; then
+
+case $package in
+ qt-copy)
+ version=3.1_20021104
+ ;;
+ arts)
+ version=1.5.10
+ ;;
+ kdevelop)
+ version=3.5.3
+ ;;
+ koffice)
+ version=1.3.98
+ ;;
+ koffice-l10n)
+ version=1.3.98
+ ;;
+ *)
+ version=3.5.10
+ ;;
+esac
+
+fi
+
+isl10n=0
+case $package in
+ *-l10n|*-i18n)
+ isl10n=1
+ ;;
+esac
+
+if test -z "$scriptpath"; then
+ scriptpath=".."
+fi
+
+export CDPATH=""
+export UNSERMAKE=no # very important for now :)
+export package version scriptpath isl10n
+
diff --git a/release/compile_all b/release/compile_all
new file mode 100755
index 0000000..73a44cb
--- /dev/null
+++ b/release/compile_all
@@ -0,0 +1,63 @@
+#!/bin/bash
+
+CDPATH=""
+summary=~/.built_summary
+log=~/.built_log
+name=`basename $0`
+
+date > $summary
+date > $log
+config=`cat config.options`
+pwd=$PWD
+for a in `cat modules`; do
+cd build
+echo "rm -rf $a*"
+rm -rf $a*
+cat ../sources/$a*.bz2 | bunzip2 | tar -xf -
+cd $a*
+ result=0
+ if [ -e nobuild ]; then
+ action="Skipping"
+ result=1
+ fi
+ if [ $result$name == 0compile_all ]; then
+ action="Configuring $PWD"
+ echo $action
+ rm config.cache >> $log 2>&1
+ ./configure $config >> $log 2>&1
+ result=$?
+ fi
+ if [ $result == 0 ]; then
+ action="Compiling $PWD"
+ echo $action
+ make >> $log 2>&1
+ result=$?
+ fi
+ if [ $result == 0 ]; then
+ action="Installing $PWD"
+ echo $action
+ make install >> $log 2>&1
+ result=$?
+ fi
+ if [ $result == 0 ]; then
+ action="Done"
+ echo $action
+ fi
+
+ if [ "$action" == "Skipping" ]; then
+ echo $PWD skipped.
+ echo $PWD skipped. >> $summary
+ elif [ "$action" == "Done" ]; then
+ echo $PWD build ok. >> $summary
+ touch nobuild
+ else
+ echo ERROR during $action
+ echo ERROR during $action >> $summary
+ if [ $a == kdelibs ]; then
+ echo Aborted!
+ echo Aborted! >> $summary
+ exit 1;
+ fi
+ fi
+ cd $pwd;
+done
diff --git a/release/config.options b/release/config.options
new file mode 100644
index 0000000..4617c70
--- /dev/null
+++ b/release/config.options
@@ -0,0 +1 @@
+--enable-final
diff --git a/release/create_all_changelogs b/release/create_all_changelogs
new file mode 100755
index 0000000..841cada
--- /dev/null
+++ b/release/create_all_changelogs
@@ -0,0 +1,8 @@
+. versions
+
+mkdir changelogs
+for mod in `cat modules`; do
+ set_urls $mod
+ svn log -v --stop-on-copy --xml -r774904:850549 $SVNPROTOCOL://[email protected]/home/kde/$HEADURL | python svn2log.py &&
+ mv ChangeLog changelogs/$mod.txt
+done
diff --git a/release/create_sources_inc b/release/create_sources_inc
new file mode 100644
index 0000000..71e1c7b
--- /dev/null
+++ b/release/create_sources_inc
@@ -0,0 +1,32 @@
+echo '<table border="0" cellpadding="4" cellspacing="0">'
+echo '<tr valign="top">'
+echo ' <th align="left">Location</th>'
+echo ' <th align="left">Size</th>'
+echo ' <th align="left">MD5&nbsp;Sum</th>'
+echo '</tr>'
+
+for i in *.tar.bz2; do
+ echo '<tr valign="top">'
+ l=`echo $i | sed -e "s#.tar.bz2##"`
+ echo ' <td><a href="http://download.kde.org/stable/3.5.10/src/'$i'">'$l'</a></td>'
+ size=`stat -c "%s" $i`
+ size=`echo "$size / 1024" | bc`
+ if test "$size" -lt 1024; then
+ size="$size"kB
+ else
+ size=`echo "($size * 10) / 1024" | bc`
+ if test "$size" -lt 100; then
+ size=`echo "$size"MB | sed -e "s#\(.\)MB#.\1MB#"`
+ else
+ size=`echo "$size"MB | sed -e "s#\(.\)MB#MB#"`
+ fi
+ fi
+ echo ' <td align="right">'$size'</td>'
+ md5=`md5sum $i | cut -f1 -d' '`
+ echo ' <td><tt>'$md5'</tt></td>'
+ echo '</tr>'
+ echo ''
+done
+
+echo '</table>'
+
diff --git a/release/difftarball b/release/difftarball
new file mode 100755
index 0000000..33a0c56
--- /dev/null
+++ b/release/difftarball
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+sources=sources-oldrc5
+test -z "$1" && { echo "parameter required"; exit 1; }
+package=$1
+test -r clean/$package || { echo "no clean/$package"; exit 1; }
+test `ls -1 $sources/$package*bz2 | wc -l` = "1" || { echo "no tarball!"; exit 1; }
+tarball="$sources/$package*bz2"
+TOPLEVEL=`tar tjf $tarball | head -1 | sed -e 's,/$,,' `
+
+rm -rf build/$package*
+cd build
+tar xjf ../$tarball
+diff -xMakefile.in -xCVS -aur $TOPLEVEL ../clean/$package > $package-diff
+less $package-diff
diff --git a/release/dist b/release/dist
new file mode 100755
index 0000000..b148b4e
--- /dev/null
+++ b/release/dist
@@ -0,0 +1,18 @@
+(
+ source `dirname $0`/common $1 $2
+ cd $package
+
+ if [ $package = "qt-copy" ] || [ $package = "kdoc" ]; then
+ make -f Makefile.cvs || exit 1
+ elif test $isl10n -eq 1; then
+ cat subdirs | while read lang; do
+ scripts/autogen.sh $lang || exit 1
+ done
+ else
+ make -f admin/Makefile.common dist || exit 1
+ fi
+
+ # remove junk
+ find . -maxdepth 3 -type d -name autom4te.cache | xargs rm -rf
+
+) || exit 1
diff --git a/release/docu b/release/docu
new file mode 100755
index 0000000..0e589dc
--- /dev/null
+++ b/release/docu
@@ -0,0 +1,38 @@
+CDPATH=
+
+adir=`dirname $0`
+adir=`cd $adir && pwd`
+files=`cd $1 && find . -type f -path "*doc*index.docbook"`
+for f in $files; do
+ (
+ dir=`dirname $f`
+
+ # is it cached ?
+ if test -f $adir/cache/$1/$dir/index.cache.bz2; then
+ cp $adir/cache/$1/$dir/index.cache.bz2 $1/$dir
+ fi
+
+ cd $1/$dir
+ echo `pwd`
+
+ if test ! -f index.cache.bz2; then
+
+ if test ! -x "`which meinproc`"; then
+ echo ""
+ echo "!!! No meinproc found. No docu generated.. !!!";
+ echo ""
+ else
+ echo Running `which meinproc` --cache index.cache.bz2 index.docbook
+ meinproc --cache index.cache.bz2 index.docbook
+ mkdir -p $adir/cache/$1/$dir
+ cp index.cache.bz2 $adir/cache/$1/$dir/
+ if test "$?" != 0; then
+ echo $1/$f >> $adir/source/FAILED
+ fi
+ fi
+ fi
+ )
+done
+
+# make sure we leave no corefiles behind
+find $1 -type f -name "core" | xargs rm -f
diff --git a/release/dosnapshot b/release/dosnapshot
new file mode 100755
index 0000000..0e7b032
--- /dev/null
+++ b/release/dosnapshot
@@ -0,0 +1,64 @@
+#! /bin/sh
+
+umask 022
+export VERBOSE=yes
+export DOINGSNAPSHOT=yes
+
+renice 20 $$ &>/dev/null
+
+(cd ~/prod && svn up -N)
+
+# lets go work
+cd ~/prod
+rm -rf sources-old
+mkdir sources-old
+mkdir sources-old/kde-l10n
+# now lets populate the directory
+for i in `cat snapmodules`; do
+ t=`readlink "ftp/$i.tar.bz2"`
+ if test -n "$t"; then
+ test -r "ftp/$t" && ln -s "../ftp/$t" sources-old
+ else
+ echo "ERROR: $i does not exist in ftp/.";
+ fi
+done
+rm -rf sources
+mkdir sources
+mkdir sources/kde-l10n
+
+version=`date +%y%m%d`
+
+for i in `cat snapmodules`; do
+(
+ test -d clean/$i || { echo "$i doesn't exist"; exit 1; }
+
+ oldrev=`readlink ftp/$i.tar.bz2 | egrep -o '[0-9]+\.tar\.bz2' | cut -d. -f1`
+ test -n "$oldrev" || oldrev=0
+
+ ( cd clean/$i && svn up >/dev/null )
+
+ newrev=`svn info clean/$i | grep 'Last Changed Rev:' | cut -d' ' -f4`
+
+ if test "$oldrev" -ne "$newrev"; then
+ ./pack $i $newrev
+ set -x
+ rm -f ftp/$i*bz2
+ mv -f sources/$i*bz2 ftp
+ ln -s $i-$newrev.tar.bz2 ftp/$i.tar.bz2
+ find ftp/ -name "$i*xdelta" -mtime +7 | xargs rm -f
+ mv -f sources/$i*xdelta ftp
+ if test "$i" = "kde-l10n"; then
+ rm -f ftp/$i/$i*bz2
+ for ki in sources/$i/$i*bz2; do
+ mv $ki ftp/kde-l10n
+ ln -s `basename $ki` ftp/kde-l10n/`basename $ki -$newrev.tar.bz2`.tar.bz2
+ done
+ fi
+ set +x
+ else
+ echo "$i does not need to be updated"
+ fi
+
+ ( cd dirty && rm -rf $i* )
+)
+done
diff --git a/release/koffice-l10n b/release/koffice-l10n
new file mode 100755
index 0000000..b899c54
--- /dev/null
+++ b/release/koffice-l10n
@@ -0,0 +1,132 @@
+#!/bin/sh
+# koffice-l10n - Creates a copy of branches/stable/l10n that contains
+# only the koffice l10n files. Useful for tagging
+# koffice-l10n without checkout out entire KDE l10n.
+#
+# Set ALT_LANGS to a space-delimited list of language
+# codes for languages for which trunk/l10n should be used.
+#
+# Usage (tagging):
+# Firstly:
+# echo koffice-l10n > modules
+# Update DESTURL in the `versions' file
+# Update version numbers in `common' file
+# Run this (setting ALT_LANGS first if necessary): ./koffice-l10n
+# cd clean/tags-koffice/*/koffice-l10n && sh $OLDPWD/select-l10n
+# mv language_list.new subdirs
+# (Apply any changes requested by translators)
+
+# Then (two commit version):
+# Commit in clean/tags-koffice
+# mv clean/tags-koffice/*/koffice-l10n clean
+# cd clean && DO_SVN=1 ../removestuff koffice-l10n
+# Commit in clean/koffice-l10n
+
+# Or (hairy one commit version):
+# sed -i 's/svn rm/svn rm --force/' removestuff
+# mv clean/tags-koffice/*/koffice-l10n* clean/koffice-l10n
+# cd clean && DO_SVN=1 ../removestuff koffice-l10n
+# mv clean/koffice-l10n clean/tags-koffice/*/koffice-l10n*
+# Commit in clean/tags-koffice
+# mv clean/tags-koffice/*/koffice-l10n* clean/koffice-l10n
+
+# Finally:
+# From release/, ./pack koffice-l10n
+# (Pack requires kdelibs, bzip2, automake and - to avoid stupid
+# warnings - libtool :o) )
+
+#SVNUSER=martin
+#SVNPROTOCOL=https
+#ALT_LANGS=""
+KOFFICE_L10N=branches/stable/l10n
+KOFFICE_L10N_ALT=trunk/l10n
+
+test -n "$SVNUSER" || { echo "You must set SVNUSER"; exit 1; }
+test -n "$SVNPROTOCOL" || { echo "You must set SVNPROTOCOL"; exit 1; }
+BASE=$SVNPROTOCOL://[email protected]/home/kde
+#BASE=svn://anonsvn.kde.org/home/kde
+
+set -e
+
+# Get the version number from the versions script
+. versions
+set_urls koffice-l10n
+VERSION=`echo $DESTURL|sed 's#^tags/koffice/\(.*\)/koffice-l10n#\1#'`
+
+# Check the version number is sane
+if test 0 -ne `(echo "$VERSION" | grep -c "[^0-9\.]") || true` ; then
+ echo "Didn't understand koffice-l10n version number: $VERSION"
+ exit 1
+fi
+
+echo "Preparing checkout for koffice-l10n-$VERSION"
+
+# Create the checkout dir if it doesn't exist
+if test ! -d clean ; then
+ mkdir clean
+fi
+
+STARTDATE=`date -R`
+(
+echo "Started tagging at $STARTDATE"
+
+cd clean
+echo "Creating a work directory..."
+svn co -N $BASE/tags/koffice tags-koffice
+cd tags-koffice
+REV=`svnversion`
+svn up -N $VERSION
+if test ! -d $VERSION ; then
+ svn mkdir $VERSION
+fi
+svn mkdir $VERSION/koffice-l10n
+cd $VERSION/koffice-l10n
+
+# Copy the top level l10n files ...
+L10N=$BASE/$KOFFICE_L10N
+L10N_ALT=$BASE/$KOFFICE_L10N_ALT
+
+echo "Copying top level l10n files from $KOFFICE_L10N."
+for d in COPYING INSTALL README subdirs teamnames ; do
+ svn cp -r $REV $L10N/$d .
+done
+
+echo "Copying the l10n scripts"
+svn cp -r $REV $L10N/scripts .
+
+echo "Replacing l10n external admin dir with a copy"
+svn propget svn:externals scripts | while read subdir url; do
+ test -n "$url" || continue
+ rm -rf scripts/$subdir
+ svn copy ${url/https:\/\//$SVNPROTOCOL://$SVNUSER@} scripts/$subdir
+done
+svn propdel svn:externals scripts
+
+echo "Copying the language packs"
+for lang in `cat subdirs` ; do
+
+ # Should we grab the language pack from the alternative location?
+ use_alt_loc=`(echo "$ALT_LANGS" | grep -wc "$lang") || true`
+ if test $use_alt_loc -eq 0 ; then
+ URL=$L10N
+ else
+ URL=$L10N_ALT
+ fi
+
+ echo "Copying language files for $lang from $URL"
+ svn mkdir $lang
+ for sub in data docs messages ; do
+ # According to the removestuff script, anything except Makefile.am
+ # and the koffice dir are deleted anyway, so lets just get them.
+ svn mkdir $lang/$sub
+ svn cp -r $REV $URL/$lang/$sub/koffice $lang/$sub || true
+ if [ "$sub" = data ] ; then
+ svn cp -r $REV $URL/$lang/$sub/Makefile.am $lang/$sub || true
+ fi
+ done
+done
+
+FINISHDATE=`date -R`
+echo "Finished tagging at $FINISHDATE"
+
+) | tee koffice-l10n-`date --date "$STARTDATE" +%Y%m%d%-k%M%S`.log
diff --git a/release/language_list b/release/language_list
new file mode 100644
index 0000000..d4d6acc
--- /dev/null
+++ b/release/language_list
@@ -0,0 +1,71 @@
+af
+ar
+az
+be
+bg
+bn
+br
+bs
+ca
+cs
+csb
+cy
+da
+de
+el
+en_GB
+eo
+es
+et
+eu
+fa
+fi
+fr
+fy
+ga
+gl
+he
+hi
+hr
+hu
+is
+it
+ja
+km
+kk
+ko
+lt
+lv
+mk
+mn
+ms
+nb
+nds
+nl
+nn
+pa
+pl
+pt
+pt_BR
+ro
+ru
+rw
+se
+sk
+sl
+sr
+sr@Latn
+ss
+sv
+ta
+te
+tg
+th
+tr
+uk
+uz
+uz@cyrillic
+vi
+wa
+zh_CN
+zh_TW
diff --git a/release/modules b/release/modules
new file mode 100644
index 0000000..7e05b4e
--- /dev/null
+++ b/release/modules
@@ -0,0 +1,20 @@
+arts
+kdeaccessibility
+kdeaddons
+kdeadmin
+kdeartwork
+kdebindings
+kdeedu
+kdegames
+kdegraphics
+kdemultimedia
+kdenetwork
+kdesdk
+kdetoys
+kdeutils
+kdevelop
+kdewebdev
+kdepim
+kdebase
+kdelibs
+kde-i18n
diff --git a/release/pack b/release/pack
new file mode 100755
index 0000000..410f13c
--- /dev/null
+++ b/release/pack
@@ -0,0 +1,60 @@
+#!/bin/bash
+# This is the main script.
+# Call it with the package name as argument, like: ./pack kdelibs
+# Make sure to update the version numbers inside "common" first.
+#
+# Environment variables that can be set
+# $scriptpath = path to kde-common/release (by default: .. )
+
+source `dirname $0`/common $1 $2
+
+MEINPROCPATH=`type -p meinproc`
+if test -f "$MEINPROCPATH"; then
+ MEINPROCPATH=`dirname $MEINPROCPATH`
+fi
+if test -n "$MEINPROCPATH"; then
+ export PATH=$MEINPROCPATH:/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin
+ echo "PATH changed to $PATH"
+fi
+test -n "$package" || { echo "requires modulename as parameter"; exit 1; }
+test -d clean || { echo "create clean subdir with cvs checkout"; exit 1; }
+test -d dirty || mkdir dirty || { echo "create empty subdir dirty"; exit 1; }
+test -d sources || mkdir sources || { echo "create empty subdir sources"; exit 1; }
+test -d sources-old || { echo "create empty subdir sources-old with reference files for xdelta"; exit 1; }
+if test $isl10n -eq 1; then
+ test -d sources/$package || mkdir sources/$package || { echo "create empty subdir sources/$package"; exit 1; }
+fi
+
+test -d clean/$package || { echo "clean/$package does not exist"; exit 1; }
+test -d dirty/$package-$version && { echo "rm -rf dirty/$package-$version"; rm -rf dirty/$package-$version; }
+test -d dirty/$package && { echo "rm -rf dirty/$package"; rm -rf dirty/$package; }
+
+if test -z "$HARDLINKS"; then
+ echo "cp -pr clean/$package dirty"
+ cp -pr clean/$package dirty || exit 1
+else
+ echo "cp -prl clean/$package dirty"
+ cp -prl clean/$package dirty || exit 1
+fi
+
+echo "cd dirty"
+cd dirty || exit 1
+
+# Anonymize checkout
+echo "anon $package"
+$scriptpath/anon $package || exit 1
+
+if test -z "$DOINGSNAPSHOT"; then
+ # Generate docu
+ echo "docu $package"
+ $scriptpath/docu $package
+fi
+
+# Prepare for distribution
+echo "dist $package"
+$scriptpath/dist $package $version || exit 1
+
+# Final packaging
+echo "taritup $package"
+$scriptpath/taritup $package $version || exit 1
+
diff --git a/release/pack_all b/release/pack_all
new file mode 100755
index 0000000..f03f4d2
--- /dev/null
+++ b/release/pack_all
@@ -0,0 +1 @@
+for i in `cat modules`; do ./pack $i; done
diff --git a/release/removestuff b/release/removestuff
new file mode 100755
index 0000000..96e593b
--- /dev/null
+++ b/release/removestuff
@@ -0,0 +1,118 @@
+# This is a helper script, which removes the useless stuff from some modules.
+# For instance it separates the koffice translations between kde-l10n and koffice-l10n.
+# Call it with the package name as argument, like: ./removestuff kde-l10n
+
+# This is called by tag_all with DO_SVN=1 in order to remove unused stuff from a tag.
+
+source `dirname $0`/common $1 $2
+
+rm_command="rm -rf"
+if test -n "$DO_SVN"; then
+ rm_command="svn rm"
+fi
+
+cd_package()
+{
+ if test -n "$version" && test -d $package-$version; then
+ cd $package-$version
+ else
+ cd $package || { echo "bah! $package doesn't exist in $PWD"; exit 1; }
+ fi
+}
+
+ if [ $package = "koffice-l10n" ]; then
+ (
+ cd_package
+ echo "Removing non-koffice stuff"
+ $rm_command templates
+ if grep -E -q '[a-z] +$' subdirs; then
+ echo "subdirs has a trailing space on a line! This breaks stuff, fix it."
+ exit 1
+ fi
+ cat subdirs | while read lang; do
+ cd $lang || continue
+ echo $lang
+ $rm_command internal
+ $rm_command docmessages
+ $rm_command webmessages
+ $rm_command */messages/koffice/kdgantt.po
+ for sub in messages docs data; do
+ test -d $sub || continue
+ cd $sub
+ for i in *; do
+ test $i != "koffice" -a $i != "Makefile.am" && $rm_command $i
+ done
+ cd ..
+ files=`ls -1 $sub | wc -l`
+ test $files -eq 0 && $rm_command $sub
+ done
+ cd ..
+ done
+ echo "Removing template specific stuff"
+ $rm_command templates
+ echo "Removing documentation links"
+ $rm_command documentation
+ $rm_command debian
+ ) || exit 1
+ fi
+
+ if [ $package = "kde-l10n" -o $package = "kde-i18n" ]; then
+ (
+ cd_package
+ echo "Removing other stuff"
+ cat subdirs | while read lang; do
+ cd $lang || continue
+ $rm_command internal
+ $rm_command docmessages
+ $rm_command webmessages
+ $rm_command messages/*/desktop_*
+ $rm_command messages/others
+ $rm_command docs/others
+ $rm_command messages/kdenonbeta
+ $rm_command docs/kdenonbeta
+ $rm_command messages/extragear-*
+ $rm_command docs/extragear-*
+ $rm_command messages/kdekiosk
+ $rm_command docs/kdekiosk
+ $rm_command messages/play*
+ $rm_command messages/kdereview
+ $rm_command docs/kdereview
+ $rm_command docs/play*
+ $rm_command */koffice
+ test -d docs/common || {
+ echo "$lang/docs/common not translated, removing"
+ $rm_command docs
+ }
+ cd ..
+ done
+ echo "Removing template specific stuff"
+ $rm_command templates
+ echo "Removing documentation links"
+ $rm_command documentation
+ )
+ fi
+
+ if [ $package = "kde-l10n" -o $package = "koffice-l10n" -o $package = "kde-i18n" ]; then
+ (
+ cd_package
+ echo Removing non-released languages from package
+ grep ^xx subdirs && { echo "$package/subdirs contains the xx language!"; exit 1; }
+ for dir in *; do
+ if test -d $dir/messages -o -d $dir/docs; then
+ if grep -q ^$dir\$ subdirs; then
+ echo Keeping $dir
+ else
+ echo Deleting $dir
+ $rm_command $dir
+ fi
+ fi
+ done
+ ) || exit 1
+ fi
+
+ # generic stuff
+ (
+ cd_package
+ rm -f svn-commit*.*
+ )
+
diff --git a/release/select-l10n b/release/select-l10n
new file mode 100644
index 0000000..54d7dbe
--- /dev/null
+++ b/release/select-l10n
@@ -0,0 +1,33 @@
+#!/bin/bash
+
+# Select the languages with enough translations for a single-module release (e.g. koffice)
+# Run this script *first* (on a complete l10n checkout), before running tag_all.
+module=koffice
+
+cp -f /dev/null ../../language_list.new
+total=0
+for i in en_GB/messages/$module/*.po; do
+ n=`msgfmt --statistics -o /dev/null $i 2>&1 | sed -e 's/,.*$//' | cut -d' ' -f1`
+ total=$((total + $n))
+done
+required=$((total * 70 / 100))
+required=`echo $required | sed -e 's/\..*//'`
+echo "$total messages to translate, $required required as a minimum."
+for lang in *; do
+ sum=0
+ if test "$lang" != "templates" -a -d $lang/messages/$module; then
+ for i in $lang/messages/$module/*.po; do
+ n=`msgfmt --statistics -o /dev/null $i 2>&1 | sed -e 's/,.*$//' | cut -d' ' -f1`
+ sum=$((sum + $n))
+ done
+ if test $sum -gt $required; then
+ echo $lang: $sum/$total, keeping
+ echo $lang >> ../../language_list.new
+ else
+ echo $lang: $sum/$total, dropping
+ #rm -rf $lang
+ fi
+ fi
+done
+echo "Languages selected, consider doing \"mv language_list.new language_list\" if OK"
+
diff --git a/release/snapmodules b/release/snapmodules
new file mode 100644
index 0000000..27e1735
--- /dev/null
+++ b/release/snapmodules
@@ -0,0 +1,46 @@
+qt-copy
+arts
+kdesupport
+kdelibs
+kdeaccessibility
+kdebase
+kdebindings
+kdenetwork
+kdegraphics
+kdeadmin
+kdemultimedia
+kdegames
+kdeutils
+kdetoys
+kdepim
+kdesdk
+kdeaddons
+kdeartwork
+kdeedu
+kdekiosk
+kdeextragear-libs
+kdeextragear-addons
+kdeextragear-graphics
+kdeextragear-multimedia
+kdeextragear-network
+kdeextragear-office
+kdeextragear-pim
+kdeextragear-security
+kdeextragear-sysadmin
+kdeextragear-toys
+kdeextragear-utils
+kdeplayground-artwork
+kdeplayground-base
+kdeplayground-edu
+kdeplayground-games
+kdeplayground-ioslaves
+kdeplayground-multimedia
+kdeplayground-network
+kdeplayground-pim
+kdeplayground-sysadmin
+kdeplayground-utils
+kdereview
+koffice
+kde-l10n
+kdevelop
+kdewebdev
diff --git a/release/svn2log.py b/release/svn2log.py
new file mode 100644
index 0000000..a216b8e
--- /dev/null
+++ b/release/svn2log.py
@@ -0,0 +1,322 @@
+#!/usr/bin/python
+# -*- coding: UTF-8 -*-
+#
+# Copyright (c) 2003 The University of Wroclaw.
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+# 1. Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. The name of the University may not be used to endorse or promote
+# products derived from this software without specific prior
+# written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE UNIVERSITY ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN
+# NO EVENT SHALL THE UNIVERSITY BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
+# TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+# PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+# LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+# NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#
+
+import sys
+import os
+import time
+import re
+import getopt
+import string
+import codecs
+import locale
+
+from xml.utils import qp_xml
+
+kill_prefix_rx = None
+default_domain = "localhost"
+exclude = []
+users = { }
+reloc = { }
+max_join_delta = 3 * 60
+list_format = False
+
+date_rx = re.compile(r"^(\d+-\d+-\d+T\d+:\d+:\d+)")
+
+def die(msg):
+ sys.stderr.write(msg + "\n")
+ sys.exit(1)
+
+def attr(e, n):
+ return e.attrs[("", n)]
+
+def has_child(e, n):
+ for c in e.children:
+ if c.name == n: return 1
+ return 0
+
+def child(e, n):
+ for c in e.children:
+ if c.name == n: return c
+ die("<%s> doesn't have <%s> child" % (e.name, n))
+
+def convert_path(n):
+ for src in reloc.keys():
+ n = string.replace(n, src, reloc[src])
+ if kill_prefix_rx != None:
+ if kill_prefix_rx.search(n):
+ n = kill_prefix_rx.sub("", n)
+ else:
+ return None
+ if n.startswith("/"): n = n[1:]
+ if n == "": n = "/"
+ for pref in exclude:
+ if n.startswith(pref):
+ return None
+ return n
+
+def convert_user(u):
+ if users.has_key(u):
+ return users[u]
+ else:
+ return u
+
+def wrap_text_line(str, pref, width):
+ ret = u""
+ line = u""
+ first_line = True
+ for word in str.split():
+ if line == u"":
+ line = word
+ else:
+ if len(line + u" " + word) > width:
+ if first_line:
+ ret += line + u"\n"
+ first_line = False
+ line = word
+ else:
+ ret += pref + line + u"\n"
+ line = word
+ else:
+ line += u" " + word
+ if first_line:
+ ret += line + u"\n"
+ else:
+ ret += pref + line + u"\n"
+ return ret
+
+def wrap_text(str, pref, width):
+ if not list_format:
+ return wrap_text_line(str,pref,width)
+ else:
+ items = re.split(r"\-\s+",str)
+ ret = wrap_text_line(items[0],pref,width)
+ for item in items[1:]:
+ ret += pref + u"- " + wrap_text_line(item,pref+" ",width)
+ return ret
+
+class Entry:
+ def __init__(self, tm, rev, author, msg):
+ self.tm = tm
+ self.rev = rev
+ self.author = author
+ self.msg = msg
+ self.beg_tm = tm
+ self.beg_rev = rev
+
+ def join(self, other):
+ self.tm = other.tm
+ self.rev = other.rev
+ self.msg += other.msg
+
+ def dump(self, out):
+ sys.stderr.write(self.rev+"\n")
+ if self.rev != self.beg_rev:
+ out.write("%s [r%s-%s] %s\n\n" % \
+ (time.strftime("%Y-%m-%d %H:%M +0000", time.localtime(self.beg_tm)), \
+ self.rev, self.beg_rev, convert_user(self.author)))
+ else:
+ out.write(u"%s [r%s] %s\n\n" % \
+ (time.strftime("%Y-%m-%d %H:%M +0000", time.localtime(self.beg_tm)), \
+ self.rev, convert_user(self.author)))
+ out.write(self.msg)
+
+ def can_join(self, other):
+ return self.author == other.author and abs(self.tm - other.tm) < max_join_delta
+
+def process_entry(e):
+ rev = attr(e, "revision")
+ if has_child(e, "author"):
+ author = child(e, "author").textof()
+ else:
+ author = "anonymous"
+ m = date_rx.search(child(e, "date").textof())
+ msg = child(e, "msg").textof()
+ if m:
+ tm = time.mktime(time.strptime(m.group(1), "%Y-%m-%dT%H:%M:%S"))
+ else:
+ die("evil date: %s" % child(e, "date").textof())
+ paths = []
+ for path in child(e, "paths").children:
+ if path.name != "path": die("<paths> has non-<path> child")
+ nam = convert_path(path.textof())
+ if nam != None:
+ if attr(path, "action") == "D":
+ paths.append(nam + " (removed)")
+ elif attr(path, "action") == "A":
+ paths.append(nam + " (added)")
+ else:
+ paths.append(nam)
+
+ if msg.startswith("SVN_SILENT"):
+ return None
+
+ if msg.startswith("CVS_SILENT"):
+ return None
+
+ if msg.startswith("This commit was manufactured by cvs2svn to create branch"):
+ return None
+
+ if paths != []:
+ return Entry(tm, rev, author, "\t* %s\n" % wrap_text(", ".join(paths) + ": " + msg, "\t ", 65))
+
+ return None
+
+def process(fin, fout):
+ parser = qp_xml.Parser()
+ root = parser.parse(fin)
+
+ if root.name != "log": die("root is not <log>")
+
+ cur = None
+
+ for logentry in root.children:
+ if logentry.name != "logentry": die("non <logentry> <log> child")
+ e = process_entry(logentry)
+ if e != None:
+ if cur != None:
+ if cur.can_join(e):
+ cur.join(e)
+ else:
+ cur.dump(fout)
+ cur = e
+ else: cur = e
+
+ if cur != None: cur.dump(fout)
+
+def usage():
+ sys.stderr.write(\
+"""Usage: %s [OPTIONS] [FILE]
+Convert specified subversion xml logfile to GNU-style ChangeLog.
+
+Options:
+ -p, --prefix=REGEXP set root directory of project (it will be striped off
+ from ChangeLog entries, paths outside it will be
+ ignored)
+ -x, --exclude=DIR exclude DIR from ChangeLog (relative to prefix)
+ -o, --output set output file (defaults to 'ChangeLog')
+ -d, --domain=DOMAIN set default domain for logins not listed in users file
+ -u, --users=FILE read logins from specified file
+ --users-charset=ENCODING
+ specify encoding of users. defaults to ISO8859-1
+ -F, --list-format format commit logs with enumerated change list (items
+ prefixed by '- ')
+ -r, --relocate=X=Y before doing any other operations on paths, replace
+ X with Y (useful for directory moves)
+ -D, --delta=SECS when log entries differ by less then SECS seconds and
+ have the same author -- they are merged, it defaults
+ to 180 seconds
+ -h, --help print this information
+
+Users file is used to map svn logins to real names to appear in ChangeLog.
+If login is not found in users file "login <login@domain>" is used.
+
+Example users file:
+john John X. Foo <[email protected]>
+mark Marcus Blah <[email protected]>
+
+Typical usage of this script is something like this:
+
+ svn log -v --xml | %s -p '/foo/(branches/[^/]+|trunk)' -u aux/users
+
+Please send bug reports and comments to author:
+ Michal Moskal <[email protected]>
+
+""" % (sys.argv[0], sys.argv[0]))
+
+def utf_open(name, mode):
+ return codecs.open(name, mode, encoding="utf-8", errors="replace")
+
+def process_opts():
+ try:
+ opts, args = getopt.gnu_getopt(sys.argv[1:], "o:u:p:x:d:r:d:D:Fh",
+ ["users-charset=", "users=", "prefix=", "domain=", "delta=",
+ "exclude=", "help", "output=", "relocate=",
+ "list-format"])
+ except getopt.GetoptError:
+ usage()
+ sys.exit(2)
+ fin = sys.stdin
+ fout = None
+ users_file = None
+ users_charset = 'ISO8859-1'
+ global kill_prefix_rx, exclude, users, default_domain, reloc, max_join_delta, list_format
+ for o, a in opts:
+ if o in ("--prefix", "-p"):
+ kill_prefix_rx = re.compile("^" + a)
+ elif o in ("--exclude", "-x"):
+ exclude.append(a)
+ elif o in ("--help", "-h"):
+ usage()
+ sys.exit(0)
+ elif o in ("--output", "-o"):
+ fout = utf_open(a, "w")
+ elif o in ("--domain", "-d"):
+ default_domain = a
+ elif o in ("--users", "-u"):
+ users_file = a
+ elif o in ("--users-charset"):
+ users_charset = a
+ elif o in ("--relocate", "-r"):
+ (src, target) = a.split("=")
+ reloc[src] = target
+ elif o in ("--delta", "-D"):
+ max_join_delta = int(a)
+ elif o in ("--list-format", "-F"):
+ list_format = True
+ else:
+ usage()
+ sys.exit(2)
+
+ if len(args) > 1:
+ usage()
+ sys.exit(2)
+ if len(args) == 1:
+ fin = open(args[0], "r")
+ if fout == None:
+ fout = utf_open("ChangeLog", "w")
+
+ if users_file != None:
+ f = utf_open(users_file, "r")
+ for line in f.xreadlines():
+ w = line.split()
+ if len(line) < 1 or line[0] == '#' or len(w) < 2:
+ continue
+ users[w[0]] = " ".join(w[1:]).decode(users_charset)
+ process(fin, fout)
+
+if __name__ == "__main__":
+ os.environ['TZ'] = 'UTC'
+ try:
+ time.tzset()
+ except AttributeError:
+ pass
+ process_opts()
+
+# vim:ts=2:sw=2:et
diff --git a/release/tag_all b/release/tag_all
new file mode 100755
index 0000000..98bf376
--- /dev/null
+++ b/release/tag_all
@@ -0,0 +1,108 @@
+#!/bin/bash
+# This script tags all modules listed in the "modules" file.
+#
+# Make sure to fix the set_urls function so that it uses the right tags.
+# language_list becomes the subdirs file in the l10n module, make sure it's uptodate.
+# Once it's all done, the script checks out the tagged directories under clean/.
+
+#SVNUSER=coolo
+#SVNPROTOCOL=svn+ssh
+
+test -n "$SVNUSER" || { echo "You must set SVNUSER"; exit 1; }
+test -n "$SVNPROTOCOL" || { echo "You must set SVNPROTOCOL"; exit 1; }
+
+BASE=$SVNPROTOCOL://[email protected]/home/kde
+
+# Temporary checkout directory
+tagdir=tagging.$$
+
+function co_subdir {
+ echo co_subdir $1
+ if test ! -d $tagdir/$1; then
+ co_subdir `dirname $1`
+ svn up -N $tagdir/$1
+ fi
+}
+
+. versions
+
+function replace_exts {
+ svn pg svn:externals $1 | while read subdir url; do
+ test -n "$url" || continue
+ rm -rf $1/$subdir
+ svn copy ${url/https:\/\//$SVNPROTOCOL://$SVNUSER@} $1/$subdir
+ done
+ svn pd svn:externals $1
+}
+
+if test -z "$ONLY_CLEANUP"; then
+ svn co -N $BASE $tagdir
+ co_subdir tags
+fi
+
+l10n_module=""
+for i in `cat modules`; do
+ test -z "$ONLY_CLEANUP" || continue
+
+ isl10n=0
+ case $i in
+ *-l10n|*-i18n)
+ isl10n=1
+ l10n_module=$i
+ ;;
+ esac
+
+ set_urls $i
+
+ co_subdir `dirname $HEADURL`
+ tt=`dirname $DESTURL`
+ tt2=`dirname $tt`
+ if ! test -d $tagdir/$tt; then
+ svn up -N $tagdir/$tt2
+ svn up -N $tagdir/$tt
+ if ! test -d $tagdir/$tt; then
+ svn mkdir $tagdir/$tt
+ fi
+ fi
+ svn up -N $tagdir/$HEADURL
+ if test $isl10n -eq 1; then
+ svn up -N $tagdir/$HEADURL/scripts
+ fi
+ if test -d $tagdir/$DESTURL; then
+ echo "$tagdir/$DESTURL exists already"
+ else
+ svn copy $tagdir/$HEADURL $tagdir/$DESTURL
+ fi
+ replace_exts $tagdir/$DESTURL
+done
+
+if test -z "$ONLY_CLEANUP" -a -n "$l10n_module"; then
+ set_urls $l10n_module
+ cp language_list $tagdir/$DESTURL/subdirs
+ replace_exts $tagdir/$DESTURL/scripts
+fi
+
+if test -z "$ONLY_CLEANUP"; then
+ svn commit $tagdir || exit 1
+ rm -rf $tagdir
+fi
+
+cd clean
+for i in `cat ../modules`; do
+ set_urls $i
+ if test -d $subname; then
+ svn cleanup $subname
+ svn up --ignore-externals $subname
+ # svn switch has problems with externals replaced with copies
+ rm -rf $subname/admin $subname/scripts/admin $subname/libltdl
+ svn cleanup $subname
+ svn up --ignore-externals $subname
+ svn switch $BASE/$DESTURL $subname
+ else
+ svn co $BASE/$DESTURL $subname
+ fi
+ DO_SVN=1 ../removestuff $subname
+done
+
+echo "All done, now commit from clean/"
+
diff --git a/release/taritup b/release/taritup
new file mode 100755
index 0000000..95aed21
--- /dev/null
+++ b/release/taritup
@@ -0,0 +1,76 @@
+#!/bin/bash
+
+ source `dirname $0`/common $1 $2
+
+ if test $isl10n -eq 1; then
+ cd $package
+ echo "making per-language tarballs"
+ cat subdirs | while read lang; do
+ rsubdir=$package-$lang-$version
+ mv $lang $rsubdir
+ tar --owner=root --group=root -c --exclude autom4te.cache $rsubdir | bzip2 -9 > ../../sources/$package/$rsubdir.tar.bz2
+ mv $rsubdir $lang
+ done
+ cd ..
+ else
+
+ echo "mv $package $package-$version"
+ mv $package $package-$version || exit 1
+ echo "tar cjf $package-$version.tar.bz2 $package-$version"
+ tar --owner=root --group=root -cf $package-$version.tar $package-$version || exit 1
+ fi
+
+ # Xdelta
+ if test "$package" = "kde-l10n" -o "$package" = "kde-i18n"; then
+ cd ../sources
+ # for kde-l10n we only generate xdelta for the small files
+ # #### double-check this code
+ files=`cd $package && ls -1 $package-*-$version.tar.bz2 2> /dev/null`
+ for file in $files; do
+ lang=${file/$package-/}
+ lang=${lang/-$version.tar.bz2/}
+ oldlang=`ls -1 ../sources-old/$package/$package-$lang-*tar.bz2 2>/dev/null | tail -n 1`
+ if test -n "$oldlang" && test -r "$oldlang"; then
+ cp $oldlang $package
+ echo "bunzip2 $package/$package-$lang-$version.tar.bz2"
+ bunzip2 $package/$package-$lang-$version.tar.bz2
+ cd $package
+ ../$scriptpath/xdelta $package-$lang-*.bz2 $package-$lang-$version.tar
+ cd ..
+ rm -f $package/$package-$lang-*.bz2
+ echo "bzip2 $package/$package-$lang-$version.tar"
+ bzip2 $package/$package-$lang-$version.tar
+ fi
+ done
+ cd ../dirty
+
+ else
+ # generate xdeltas
+ if test "$package" = "koffice"; then
+ # For KOffice, the modules are named "koffice" and "koffice-l10n"
+ # so search for koffice*tar.bz2 returns 2 files.
+ oldpackage=`ls -1 ../sources-old/$package*tar.bz2 2>/dev/null | fgrep -v l10n`
+ else
+ # Normal case, no problem with a pseudo-duplicate
+ oldpackage=`ls -1 ../sources-old/$package*tar.bz2 2>/dev/null | tail -n 1`
+ fi
+ if test -n "$oldpackage" && test -r $oldpackage; then
+ cp $oldpackage .
+ $scriptpath/xdelta $package*tar.bz2 $package*tar
+ mv $package*.tar.xdelta ../sources
+ fi
+ fi
+
+ if test $isl10n -eq 0; then
+ echo "bzip2 -9 $package-$version.tar"
+ rm -f $package-$version.tar.bz2
+ bzip2 -9 $package-$version.tar
+ mv $package-$version.tar.bz2 ../sources
+ echo "rm -f $package*tar"
+ rm -f $package*tar
+ echo "rm -rf $package-$version"
+ rm -rf $package-$version
+ fi
+
+ rm -rf dirty/$package || exit 1
+
diff --git a/release/versions b/release/versions
new file mode 100644
index 0000000..b4f01a3
--- /dev/null
+++ b/release/versions
@@ -0,0 +1,31 @@
+function set_urls {
+case $1 in
+ arts)
+ HEADURL=branches/arts/1.5/arts
+ DESTURL=tags/arts/1.5.10/arts
+ subname=$1
+ ;;
+ kde-l10n|kde-i18n)
+ HEADURL=branches/stable/l10n
+ DESTURL=tags/KDE/3.5.10/kde-i18n
+ subname=kde-i18n
+ ;;
+ koffice-l10n)
+ HEADURL=branches/stable/l10n
+ DESTURL=tags/koffice/1.4.0/koffice-l10n
+ subname=koffice-l10n
+ ;;
+ koffice)
+ HEADURL=branches/koffice/1.4/koffice
+ DESTURL=tags/koffice/1.4.0/$1
+ subname=$1
+ ;;
+ *)
+ HEADURL=branches/KDE/3.5/$1
+ DESTURL=tags/KDE/3.5.10/$1
+ subname=$1
+ ;;
+esac
+
+}
+
diff --git a/release/xdelta b/release/xdelta
new file mode 100755
index 0000000..eb8b44a
--- /dev/null
+++ b/release/xdelta
@@ -0,0 +1,35 @@
+#!/bin/bash
+
+test -z "$1" && { echo "parameter oldtarball required"; exit 1; }
+test -z "$2" && { echo "parameter newtarball required"; exit 1; }
+
+cleanupfiles=""
+
+if test `basename $1 .bz2` != $1; then
+ echo "bunzip2 $1"
+ bunzip2 -c $1 > `basename $1 .bz2`
+ cleanupfiles="$cleanupfiles `basename $1 .bz2`"
+fi
+
+if test `basename $2 .bz2` != $2; then
+ echo "bunzip2 $2"
+ bunzip2 -c $2 > `basename $2 .bz2`
+ cleanupfiles="$cleanupfiles `basename $2 .bz2`"
+fi
+
+oldtarball=`basename $1 .bz2`
+newtarball=`basename $2 .bz2`
+
+package=`echo $newtarball | sed -e 's,-[^-]*$,,'`
+oldversion=`basename $oldtarball .tar | sed -e s,$package-,,`
+newversion=`basename $newtarball .tar | sed -e s,$package-,,`
+diffname="$package-$oldversion-$newversion.tar.xdelta"
+
+echo "xdelta $oldtarball $newtarball $diffname"
+xdelta delta -9 -m 64M $oldtarball $newtarball $diffname
+
+if test -n "$cleanupfiles"; then
+ echo "rm -f $cleanupfiles"
+ rm -f $cleanupfiles
+fi
+