aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWillem Jan Palenstijn2006-08-18 21:55:11 +0000
committerWillem Jan Palenstijn2006-08-18 21:55:11 +0000
commitd253442c42405f67bf61db60d9f5d490e12ff025 (patch)
tree41e433615aa9cbc462b8c63115c735e9aab2eb9d
parent6613b3cae246ac3f511ec1e11713b6256d95aefb (diff)
downloadscummvm-rg350-d253442c42405f67bf61db60d9f5d490e12ff025.tar.gz
scummvm-rg350-d253442c42405f67bf61db60d9f5d490e12ff025.tar.bz2
scummvm-rg350-d253442c42405f67bf61db60d9f5d490e12ff025.zip
slightly changed patch #1521412: Hardcoded path for theme files
svn-id: r23723
-rwxr-xr-xconfigure8
-rw-r--r--gui/ThemeNew.cpp4
2 files changed, 12 insertions, 0 deletions
diff --git a/configure b/configure
index 73ce76108a..7bba99bec1 100755
--- a/configure
+++ b/configure
@@ -309,6 +309,7 @@ Installation directories:
--prefix=DIR use this prefix for installing ScummVM [/usr/local]
--bindir=DIR directory to install the scummvm binary in [PREFIX/bin]
--mandir=DIR directory to install the manpage in [PREFIX/man]
+ --datadir=DIR directory to install the data files in [PREFIX/share]
Special configuration feature:
--host=HOST cross-compile to target HOST (arm-linux, ...)
@@ -500,6 +501,9 @@ for ac_option in $@; do
--mandir=*)
_mandir=`echo $ac_option | cut -d '=' -f 2`
;;
+ --datadir=*)
+ _datadir=`echo $ac_option | cut -d '=' -f 2`
+ ;;
*)
echo "error: unrecognised option: $ac_option
Try \`$0 --help' for more information." >&2
@@ -1187,6 +1191,10 @@ fi
#
test -z "$_bindir" && _bindir="$_prefix/bin"
test -z "$_mandir" && _mandir="$_prefix/man"
+test -z "$_datadir" && _datadir="$_prefix/share"
+
+DEFINES="$DEFINES -DDATA_PATH=\\\"$_datadir/scummvm\\\""
+
#
# Check which engines ("frontends") are to be built
diff --git a/gui/ThemeNew.cpp b/gui/ThemeNew.cpp
index b1dd95da72..3033f54e3b 100644
--- a/gui/ThemeNew.cpp
+++ b/gui/ThemeNew.cpp
@@ -76,6 +76,10 @@ _lastUsedBitMask(0), _forceRedraw(false), _fonts(), _imageHandles(0), _images(0)
if (ConfMan.hasKey("themepath"))
Common::File::addDefaultDirectory(ConfMan.get("themepath"));
+#ifdef DATA_PATH
+ Common::File::addDefaultDirectoryRecursive(DATA_PATH);
+#endif
+
if (ConfMan.hasKey("extrapath"))
Common::File::addDefaultDirectoryRecursive(ConfMan.get("extrapath"));