#!/bin/sh if [ $# -ne 1 ]; then echo "Usage: make-all trunk" exit 1 fi what=$1 NOT_RELEASED="heimdal dak dfs glpi opsi apache2 ssh" svn export https://oss.gonicus.de/repositories/gosa/$what/gosa-core svn export https://oss.gonicus.de/repositories/gosa/$what/gosa-plugins VERSION=$(cat gosa-core/debian/changelog | head -n 1 | sed -n -e 's/.*(\([^-]*\).*/\1/p') cp -a gosa-core gosa-$VERSION tar cvfj /usr/src/redhat/SOURCES/gosa-$VERSION.tar.bz2 gosa-$VERSION cp gosa-$VERSION/redhat/0* /usr/src/redhat/SOURCES/ sed "s/^Version:.*$/Version: $VERSION/" gosa-$VERSION/redhat/gosa.spec > /usr/src/redhat/SPECS/gosa.spec rpmbuild -bb /usr/src/redhat/SPECS/gosa.spec MAKE_PLUGINS=$(ls -1 gosa-plugins/*/plugin.dsc | sed 's/^.*\/\([^\/]*\)\/plugin.dsc$/\1/') for i in $NOT_RELEASED; do MAKE_PLUGINS=$(echo -n $MAKE_PLUGINS | sed "s/$i//") done cd gosa-plugins for plugin in $MAKE_PLUGINS; do ../gosa-core/redhat/rpm-make-gosa $plugin rpmbuild -bb /usr/src/redhat/SPECS/gosa-plugin-$plugin.spec done rm -rf gosa-core rm -rf gosa-$VERSION rm -rf gosa-plugins