summaryrefslogtreecommitdiff
path: root/build
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-11-27 23:31:18 +0300
committerAndrei Karas <akaras@inbox.ru>2014-11-27 23:31:18 +0300
commitb5042022ac2b5f0183e2c53ad9bdebfa409eb212 (patch)
treea65e528a7ab5bf316d6b36131886e585e4123a7e /build
parentda175d26e4999f69283ab3b760e7f4a9b894d355 (diff)
downloadtools-b5042022ac2b5f0183e2c53ad9bdebfa409eb212.tar.gz
tools-b5042022ac2b5f0183e2c53ad9bdebfa409eb212.tar.bz2
tools-b5042022ac2b5f0183e2c53ad9bdebfa409eb212.tar.xz
tools-b5042022ac2b5f0183e2c53ad9bdebfa409eb212.zip
build: fix script. Also add progress messages.
Diffstat (limited to 'build')
-rwxr-xr-xbuild/chroot-server-build.sh4
-rwxr-xr-xbuild/server-bin.sh9
2 files changed, 11 insertions, 2 deletions
diff --git a/build/chroot-server-build.sh b/build/chroot-server-build.sh
index 5704f5f..3cc5c87 100755
--- a/build/chroot-server-build.sh
+++ b/build/chroot-server-build.sh
@@ -8,14 +8,17 @@ export SRCDIR="$DSTDIR/server-code"
export SRCPLUGINSDIR="$SRCDIR/src/evol/build/src/.libs/"
export LOCALDIR="../../server-local/bin"
+echo Removing old files...
rm -rf "$DSTDIR"
mkdir "$DSTDIR"
+echo Coping files...
cp -r ../../server-code "$DSTDIR/server-code"
cp -r ../../server-data "$DSTDIR/server-data"
cp -r ../../server-local "$DSTDIR/server-local"
cp -r ../../tools "$DSTDIR/tools"
+echo Enter chroot...
schroot -c "$NAME" --directory "$DSTCHDIR/tools/build/" "server-bin.sh"
if [[ $? == 0 ]]; then
@@ -27,3 +30,4 @@ if [[ $? == 0 ]]; then
cp "$SRCDIR/plugins"/*.so "$LOCALDIR/plugins/"
cp -f "$SRCPLUGINSDIR"/*.so "$LOCALDIR/plugins/"
fi
+echo Exit chroot...
diff --git a/build/server-bin.sh b/build/server-bin.sh
index b81ce8f..f3cb9fa 100755
--- a/build/server-bin.sh
+++ b/build/server-bin.sh
@@ -1,11 +1,13 @@
#!/bin/bash
-export $LOCALDIR="../server-local/bin"
+export LOCALDIR="../server-local/bin"
cd ../../server-code
+echo Build server...
make clean
./build.sh static
if [[ $? == 0 ]]; then
+ echo Copy server binaries...
cp -f char-server $LOCALDIR
cp -f login-server $LOCALDIR
cp -f map-server $LOCALDIR
@@ -17,18 +19,21 @@ fi
cd src/evol
mkdir build
+echo Build evol plugin...
autoreconf -i
cd build
make clean
../configure
make -j3
-cd ..
if [[ $? == 0 ]]; then
+ cd ..
+ echo Copy plugin binaries...
mkdir ../../../server-local/bin/plugins
cp -f build/src/.libs/*.so ../../../server-local/bin/plugins
echo Build success
else
+ cd ..
echo Build failed
exit 1
fi