summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortruelight <truelight@openttd.org>2007-02-08 11:04:39 +0000
committertruelight <truelight@openttd.org>2007-02-08 11:04:39 +0000
commit062ee7d9eb95fa6fbae3ee381dc03eb24dfdf72c (patch)
treed0f7f977d46154f1bd508bc0333403cfa60dc987
parent596fb726d0887e3d6020e2aeab28ebb1a9a41d7b (diff)
downloadopenttd-062ee7d9eb95fa6fbae3ee381dc03eb24dfdf72c.tar.xz
(svn r8628) [PSP] -Add: added configure support for the PlayStation Portable target
In the coming days/weeks there will be an attempt to port OpenTTD for this target. This is a very small step towards that.
-rw-r--r--config.lib13
-rwxr-xr-xconfigure1
2 files changed, 8 insertions, 6 deletions
diff --git a/config.lib b/config.lib
index 9189c30f9..e7aa78df6 100644
--- a/config.lib
+++ b/config.lib
@@ -286,10 +286,10 @@ check_params() {
echo " Available options are: --endian=[AUTO|LE|BE]"
exit 1
fi
- # OS only allows DETECT, UNIX, OSX, FREEBSD, MORPHOS, BEOS, SUNOS, CYGWIN, MINGW, OS2, and WINCE
- if ! echo $os | grep -Eq "^(DETECT|UNIX|OSX|FREEBSD|MORPHOS|BEOS|SUNOS|CYGWIN|MINGW|OS2|WINCE)$"; then
+ # OS only allows DETECT, UNIX, OSX, FREEBSD, MORPHOS, BEOS, SUNOS, CYGWIN, MINGW, OS2, WINCE, and PSP
+ if ! echo $os | grep -Eq "^(DETECT|UNIX|OSX|FREEBSD|MORPHOS|BEOS|SUNOS|CYGWIN|MINGW|OS2|WINCE|PSP)$"; then
echo "configure: error: invalid option --os=$os"
- echo " Available options are: --os=[DETECT|UNIX|OSX|FREEBSD|MORPHOS|BEOS|SUNOS|CYGWIN|MINGW|OS2|WINCE]"
+ echo " Available options are: --os=[DETECT|UNIX|OSX|FREEBSD|MORPHOS|BEOS|SUNOS|CYGWIN|MINGW|OS2|WINCE|PSP]"
exit 1
fi
# enable_debug should be between 0 and 4
@@ -1104,7 +1104,7 @@ check_makedepend() {
detect_os() {
if [ $os = "DETECT" ]; then
- # Detect UNIX, OSX, FREEBSD, MORPHOS, BEOS, SUNOS, CYGWIN, MINGW, OS2, and WINCE
+ # Detect UNIX, OSX, FREEBSD, MORPHOS, BEOS, SUNOS, CYGWIN, MINGW, OS2, WINCE, and PSP
# Try first via dumpmachine, then via uname
os=`echo "$host" | tr [:upper:] [:lower:] | awk '
@@ -1118,6 +1118,7 @@ detect_os() {
/mingw/ { print "MINGW"; exit}
/os2/ { print "OS2"; exit}
/wince/ { print "WINCE"; exit}
+ /psp/ { print "PSP"; exit}
'`
if [ -z "$os" ]; then
@@ -1137,7 +1138,7 @@ detect_os() {
if [ -z "$os" ]; then
log 1 "detecting OS... none detected"
log 1 "I couldn't detect your OS. Please use --with-os=OS to force one"
- log 1 "Allowed values are: UNIX, OSX, FREEBSD, MORPHOS, BEOS, SUNOS, CYGWIN, MINGW, OS2 and WINCE"
+ log 1 "Allowed values are: UNIX, OSX, FREEBSD, MORPHOS, BEOS, SUNOS, CYGWIN, MINGW, OS2, WINCE, and PSP"
exit 1
fi
@@ -1744,7 +1745,7 @@ showhelp() {
echo " --lipo=LIPO the lipo to use (OSX ONLY) [HOST-lipo]"
echo " --os=OS the OS we are compiling for [DETECT]"
echo " DETECT/UNIX/OSX/FREEBSD/MORPHOS/BEOS/"
- echo " SUNOS/CYGWIN/MINGW/OS2/WINCE"
+ echo " SUNOS/CYGWIN/MINGW/OS2/WINCE/PSP"
echo " --endian=ENDIAN set the endian of the HOST (AUTO/LE/BE)"
echo " --revision=rXXXX overwrite the revision detection."
echo " Use with care!"
diff --git a/configure b/configure
index c79bd606c..27eca46b9 100755
--- a/configure
+++ b/configure
@@ -73,6 +73,7 @@ SRCS="`< $ROOT_DIR/source.list tr '\r' '\n' | awk '
if ($0 == "SDL" && "'$sdl_config'" == "") { next; }
if ($0 == "OSX" && "'$os'" != "OSX") { next; }
if ($0 == "OS2" && "'$os'" != "OS2") { next; }
+ if ($0 == "PSP" && "'$os'" != "PSP") { next; }
if ($0 == "DEDICATED" && "'$enable_dedicated'" != "1") { next; }
if ($0 == "COCOA" && "'$with_cocoa'" == "0") { next; }
if ($0 == "BEOS" && "'$os'" != "BEOS") { next; }