various tweaks/fixes after testing

This commit is contained in:
Gunter Labes 2009-05-27 20:52:32 +00:00
parent e07f94ebb0
commit 8c25099e3e
2 changed files with 6 additions and 6 deletions

View File

@ -55,7 +55,7 @@ do
DATE=$(date +"%Y%m%d-%H%M%S") DATE=$(date +"%Y%m%d-%H%M%S")
[ -r "$SERVERBASE"/redirect.cfg ] && PORT=$(sed -nre '/port=/s/[ \t]*port="?([0-9]+)"?/\1/p' "$SERVERBASE"/redirect.cfg) [ -r "$SERVERBASE"/redirect.cfg ] && PORT=$(sed -nre '/port=/s/[ \t]*port="?([0-9]+)"?/\1/p' "$SERVERBASE"/redirect.cfg)
BUILDDIR=$(readlink "$SERVERBASE"/build) BUILDDIR=$(readlink "$SERVERBASE"/build)
REV=r$(echo $BUILDDIR | sed -nre "s,.*wesnothd-svn-([0-9:SM]+)_$SERVER/$,\1,p") REV=r$(echo $BUILDDIR | sed -nre "s,.*wesnothd-svn-([0-9:SM]+)_$SERVER$,\1,p")
LOG="wesnothd.$DATE.$REV.log" LOG="wesnothd.$DATE.$REV.log"
bin/wesnothd-$SERVER -c "$SERVERBASE"/wesnothd.cfg --port $PORT --threads $THREADS $PARAMETERS > "$SERVERBASE/logs/$LOG" 2>&1 & bin/wesnothd-$SERVER -c "$SERVERBASE"/wesnothd.cfg --port $PORT --threads $THREADS $PARAMETERS > "$SERVERBASE/logs/$LOG" 2>&1 &
PID=$! PID=$!

View File

@ -2,7 +2,6 @@
die() { echo >&2 "$@"; exit 1; } die() { echo >&2 "$@"; exit 1; }
[ $# -gt 0 ] && [ $# -lt 4 ] || die "Syntax: $(basename $0) [-c] <server version> [<revision>]" [ $# -gt 0 ] && [ $# -lt 4 ] || die "Syntax: $(basename $0) [-c] <server version> [<revision>]"
set -o errexit set -o errexit
set -o nounset
VERSION="$1" VERSION="$1"
case "$VERSION" in case "$VERSION" in
@ -42,6 +41,7 @@ if [ $TYPE = campaignd ]; then
LDFLAGS="$LDFLAGS -pg" LDFLAGS="$LDFLAGS -pg"
[ "$VERSION" = "1.4" ] && SCONS=no [ "$VERSION" = "1.4" ] && SCONS=no
fi fi
set -o nounset
printf 'svn update... ' printf 'svn update... '
REVISION="${2:+-r $2}" REVISION="${2:+-r $2}"
@ -61,10 +61,10 @@ mkdir -p "$BUILD_DIR"
export CXXFLAG LDFLAGS export CXXFLAG LDFLAGS
if [ $SCONS = yes ]; then if [ $SCONS = yes ]; then
if [ $TYPE = wesnothd ]; then if [ $TYPE = wesnothd ]; then
BUILD_FLAGS="fifodir=\"$BUILD_DIR\"/var/run raw_sockets=1 forum_user_handler=1" BUILD_FLAGS="'fifodir=$BUILD_DIR/var/run' raw_sockets=1 forum_user_handler=1"
case $(hostname) in case $(hostname) in
gonzo.dicp.de) BUILD_FLAGS="fifodir=\"$BUILD_DIR\"/var/run raw_sockets=1 boostdir=\"$HOME\"/tools/include boostlibdir=\"$HOME\"/tools/lib boost_suffix=-mt" ;; gonzo.dicp.de) BUILD_FLAGS="'fifodir=$BUILD_DIR/var/run raw_sockets=1' boostdir=$HOME/tools/include boostlibdir=$HOME/tools/lib boost_suffix=-mt" ;;
basilic) BUILD_FLAGS="fifodir=\"$BUILD_DIR\"/var/run raw_sockets=1" ;; basilic) BUILD_FLAGS="'fifodir=$BUILD_DIR/var/run raw_sockets=1'" ;;
esac esac
fi fi
mkdir -p "$BUILD_DIR"/var/run mkdir -p "$BUILD_DIR"/var/run
@ -72,7 +72,7 @@ if [ $SCONS = yes ]; then
scons install-$TYPE prefix="$BUILD_DIR" program_suffix=-"$VERSION" $BUILD_FLAGS profile=0 fribidi=0 python=0 localedir= prefsdir= > "$BUILD_DIR"/scons.log scons install-$TYPE prefix="$BUILD_DIR" program_suffix=-"$VERSION" $BUILD_FLAGS profile=0 fribidi=0 python=0 localedir= prefsdir= > "$BUILD_DIR"/scons.log
else else
if [ $TYPE = wesnothd ]; then if [ $TYPE = wesnothd ]; then
BUILD_FLAGS="--enable-server --enable-raw-sockets --with-fifodir=\"$BUILD_DIR\"/var/run --with-boost="$HOME"/tools" BUILD_FLAGS="--enable-server --enable-raw-sockets '--with-fifodir=$BUILD_DIR/var/run' '--with-boost=$HOME/tools'"
else else
BUILD_FLAGS="--enable-campaign-server" BUILD_FLAGS="--enable-campaign-server"
fi fi