aboutsummaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorMarcus Comstedt2009-03-18 23:38:25 +0000
committerMarcus Comstedt2009-03-18 23:38:25 +0000
commit114d9f211cd37245cb3257c9e0ebb147c4db1a19 (patch)
tree8cf12a4dab957da5e155decc51cf316fe0f2b698 /configure
parentf32fd48930db015f123a67a5d99628f412f1750a (diff)
downloadscummvm-rg350-114d9f211cd37245cb3257c9e0ebb147c4db1a19.tar.gz
scummvm-rg350-114d9f211cd37245cb3257c9e0ebb147c4db1a19.tar.bz2
scummvm-rg350-114d9f211cd37245cb3257c9e0ebb147c4db1a19.zip
Initial support for building the Dreamcast port using the configure
script. Dynamic modules are not supported just yet. svn-id: r39524
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure40
1 files changed, 39 insertions, 1 deletions
diff --git a/configure b/configure
index 54fec9d384..3a18d4611d 100755
--- a/configure
+++ b/configure
@@ -847,6 +847,13 @@ neuros)
_host_os=linux
_host_cpu=arm
;;
+dreamcast)
+ _host_os=dreamcast
+ _host_cpu=sh
+ _host_alias=sh-elf
+ CXXFLAGS="$CXXFLAGS -ml -m4-single-only"
+ LDFLAGS="$LDFLAGS -ml -m4-single-only"
+ ;;
*)
if test -z "$_host"; then
guessed_host=`$_srcdir/config.guess`
@@ -876,6 +883,9 @@ arm-riscos)
gp2x-linux)
EXEEXT=".gp2x"
;;
+dreamcast)
+ EXEEXT=".elf"
+ ;;
*)
EXEEXT=""
;;
@@ -967,7 +977,7 @@ fi
#
if test "$_cxx_major" -ge "3" ; then
case $_host_os in
- mingw* | cygwin*)
+ mingw* | cygwin* | dreamcast)
CXXFLAGS="$CXXFLAGS -W -Wno-unused-parameter"
;;
*)
@@ -1112,6 +1122,9 @@ case $_host_os in
type_2_byte='short'
type_4_byte='long'
;;
+ dreamcast)
+ DEFINES="$DEFINES -D__DC__ -DNONSTANDARD_PORT"
+ ;;
# given this is a shell script assume some type of unix
*)
echo "WARNING: could not establish system type, assuming unix like"
@@ -1222,6 +1235,24 @@ if test -n "$_host"; then
_backend="iphone"
_build_hq_scalers="no"
;;
+ dreamcast)
+ echo "Cross-compiling to $_host, forcing endianness, alignment and type sizes"
+ DEFINES="$DEFINES -DDISABLE_DEFAULT_SAVEFILEMANAGER -DDISABLE_TEXT_CONSOLE -DDISABLE_COMMAND_LINE"
+ CXXFLAGS="$CXXFLAGS -O3 -Wno-multichar -funroll-loops -fschedule-insns2 -fomit-frame-pointer -fdelete-null-pointer-checks -fno-exceptions"
+ _endian=little
+ _need_memalign=yes
+ type_1_byte='char'
+ type_2_byte='short'
+ type_4_byte='int'
+ _backend="dc"
+ _build_scalers="no"
+ _build_hq_scalers="no"
+ _mad="yes"
+ _zlib="yes"
+ _ar="$_host_alias-ar cru"
+ _ranlib=$_host_alias-ranlib
+ add_line_to_config_mk 'include $(srcdir)/backends/platform/dc/dreamcast.mk'
+ ;;
*)
echo "Continuing with auto-detected values ... if you have problems, please add your target to configure."
;;
@@ -1706,6 +1737,12 @@ case $_backend in
DEFINES="$DEFINES -DIPHONE_BACKEND"
MODULES="$MODULES backends/platform/iphone"
;;
+ dc)
+ INCLUDES="$INCLUDES "'-I$(srcdir)/backends/platform/dc -I$(ronindir)/include'
+ LDFLAGS="$LDFLAGS -Wl,-Ttext,0x8c010000 -nostartfiles "'$(ronindir)/lib/crt0.o -L$(ronindir)/lib'
+ LIBS="$LIBS -lronin -lm"
+ MODULES="$MODULES backends/platform/dc"
+ ;;
*)
echo "support for $_backend backend not implemented in configure script yet"
exit 1
@@ -1888,6 +1925,7 @@ vpath %.c \$(srcdir)
vpath %.m \$(srcdir)
vpath %.asm \$(srcdir)
vpath %.s \$(srcdir)
+vpath %.S \$(srcdir)
include \$(srcdir)/Makefile
EOF