Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/sh
- DF_DIR=$(dirname "$0")
- cd "${DF_DIR}"
- export SDL_DISABLE_LOCK_KEYS=1 # Work around for bug in Debian/Ubuntu SDL patch.
- #export SDL_VIDEO_CENTERED=1 # Centre the screen. Messes up resizing.
- # Find 64 bit library
- LIBFILE="libstdc++.so.6"
- for d in /lib64 /lib ; do
- if [ -e $d/$LIBFILE ]; then
- # Get the file that the symbolic link points to
- CXX_LIB=`readlink -f $d/$LIBFILE`
- CXX_LIB=`basename $CXX_LIB`
- VER=`echo $CXX_LIB | sed -e 's/^.*\.so.//'`
- break
- fi
- done
- case $VER in
- 6.0.2[2-9]|6.0.3[0-9]|6.1.*)
- # Nothing to do, the system C++ lib is one we can link against.
- echo Using system libstdc++ library, version $VER
- ;;
- *)
- # Either we can't find the system C++ lib or it's of a version we can't link against,
- # so use the library that shipped with us
- echo Using bundled libstdc++ library
- export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:./c_lib
- ;;
- esac
- ./libs/Dwarf_Fortress "$@" # Go, go, go! :)
Add Comment
Please, Sign In to add comment