compile with profiling

handle profiling logs

use the new shut down feature to properly shut the server down on
ctrl+c
This commit is contained in:
Gunter Labes 2007-12-17 05:26:05 +00:00
parent 6f6033a04b
commit c3f8688eaa
2 changed files with 3 additions and 3 deletions

View file

@ -20,7 +20,7 @@ ulimit -Ss 2048
ulimit -c unlimited
# send the standard server message to the appropriate server when killing it with ctrl+c
trap "$HOME/bin/send_server_message $SERVER; sleep 2; killall wesnothd-$SERVER; echo -n 'terminated: '; date; exit 0" SIGINT
trap "$HOME/bin/send_server_message $SERVER; sleep 2; $HOME/bin/send_server_command $SERVER shut_down; wait; echo -n 'terminated: '; date; exit 0" SIGINT
while [ true ]
do
@ -41,6 +41,7 @@ do
mv currentlobby.log oldlobby.log > /dev/null 2>&1
ln -s logs/wesnothd.$DATE.$REV.log current.log
ln -s logs/lobby.$DATE.$REV.log currentlobby.log
mv gmon.out gmon.$DATE.out
# wait a bit so the server is likely up and listening
sleep 1
if [ "$SERVER" != "trunk" ]; then

View file

@ -47,8 +47,7 @@ mkdir $BUILD/$DIR
echo 'autogen.sh and configure...'
./autogen.sh > $BUILD/$DIR/autogen.log
./configure --prefix=$BUILD/$DIR --program-suffix=-$SERVER --enable-server --enable-raw-sockets --disable-game --with-fifodir=$BUILD/$DIR/var/run --disable-nls --enable-debug --enable-lite > $BUILD/$DIR/configure.log
#CXXFLAGS='-DNETWORK_USE_RAW_SOCKETS'
./configure --prefix=$BUILD/$DIR --program-suffix=-$SERVER --enable-server --enable-raw-sockets --disable-game --with-fifodir=$BUILD/$DIR/var/run --disable-nls --enable-debug --enable-lite > $BUILD/$DIR/configure.log CXXFLAGS='-pg' LDFLAGS='-pg'
make clean > /dev/null
echo 'make...'