diff options
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 43 |
1 files changed, 38 insertions, 5 deletions
@@ -129,7 +129,7 @@ Usage: $0 [OPTIONS]... Configuration: -h, --help display this help and exit - --backend=BACKEND backend to build (sdl, x11, morphos, dc, gp32) [sdl] + --backend=BACKEND backend to build (sdl, sdlgl, x11, morphos, dc, gp32) [sdl] Optional Features: --disable-scumm don't build the SCUMM engine @@ -265,14 +265,14 @@ hosttype=`uname -s` echo $hosttype case $hosttype in Linux | OpenBSD | FreeBSD | NetBSD | BSD/OS | SunOS | HP-UX) - _def_unix='/* #define UNIX */' + DEFINES="$DEFINES -DUNIX" ;; IRIX) - _def_unix='/* #define UNIX */' + DEFINES="$DEFINES -DUNIX" ranlib=ar -r ;; Darwin) - _def_unix='/* #define UNIX */' + DEFINES="$DEFINES -DUNIX" _def_macosx='#define MACOSX' LIBS="$LIBS -framework QuickTime -framework AudioUnit" ;; @@ -430,6 +430,36 @@ echo -n "Backend... " echo "$_backend" echo +# +# Backend related stuff +# +case $_backend in + sdl) + INCLUDES="$INCLUDES `$_sdlconfig --cflags`" + LIBS="$LIBS `$_sdlconfig --libs`" + OBJS="$OBJS backends/sdl/sdl-common.o backends/sdl/sdl.o" + MODULES="$MODULES backends/sdl" + ;; + sdlgl) + INCLUDES="$INCLUDES `$_sdlconfig --cflags`" + LIBS="$LIBS `$_sdlconfig --libs` -lGL" + OBJS="$OBJS backends/sdl/sdl-common.o backends/sdl/sdl_gl.o" + MODULES="$MODULES backends/sdl" + ;; + x11) + INCLUDES="$INCLUDES -I/usr/X11R6/include" + LIBS="$LIBS -lpthread -lXext -lX11" + LDFLAGS="$LDFLAGS -L/usr/X11R6/lib -L/usr/local/lib" + OBJS="$OBJS backends/x11/x11.o" + DEFINES="$DEFINES -DX11_BACKEND" + MODULES="$MODULES backends/x11" + ;; + *) + echo "support for $_backend backend not implemented in configure script yet" + exit 1 + ;; +esac + echo "Creating config.h" cat > config.h << EOF /* This file is automatically generated by configure */ @@ -442,7 +472,6 @@ $_def_scumm $_def_simon $_def_sky -$_def_unix $_def_macosx $_def_endianess $_def_align @@ -475,4 +504,8 @@ LIBS := $LIBS RANLIB := $_ranlib BACKEND := $_backend +MODULES += $MODULES +INCLUDES += $INCLUDES +OBJS += $OBJS +DEFINES += $DEFINES EOF |