mirror of
https://github.com/glest/glest-source.git
synced 2025-08-20 07:01:21 +02:00
startscript
This commit is contained in:
24
mk/linux/glest
Executable file
24
mk/linux/glest
Executable file
@@ -0,0 +1,24 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
# Library directory
|
||||||
|
LIBDIR="lib"
|
||||||
|
|
||||||
|
# If we are launching from a symlink, such as /usr/local/bin/runglest.sh, we need to get where
|
||||||
|
# the symlink points to
|
||||||
|
pth="`readlink $0`"
|
||||||
|
|
||||||
|
# $pth will be empty if our start path wasnt a symlink
|
||||||
|
if [ $pth ]; then
|
||||||
|
GAMEDIR="`dirname $pth`"
|
||||||
|
else
|
||||||
|
GAMEDIR="`dirname $0`"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Change to the game dir, and go!
|
||||||
|
cd $GAMEDIR
|
||||||
|
# export game library directory
|
||||||
|
test -n "${LIBDIR}" && export LD_LIBRARY_PATH="${LD_LIBRARY_PATH}:${GAMEDIR}/${LIBDIR}"
|
||||||
|
|
||||||
|
./glest.bin > glest.log 2>&1
|
||||||
|
# ./glest > /tmp/`date +"%F_%k-%M-%S"`.glest.log 2>&1
|
||||||
|
|
Reference in New Issue
Block a user