Can build without SDL now (only RetroArch).

This commit is contained in:
Themaister 2012-09-28 23:34:19 +02:00
parent c655c1d4e5
commit 04e3fe185f
6 changed files with 53 additions and 42 deletions

View File

@ -14,11 +14,12 @@ OBJ = retroarch.o \
gfx/gfx_common.o \
input/input_common.o \
patch.o \
fifo_buffer.o \
compat/compat.o \
screenshot.o \
audio/null.o \
gfx/null.o \
input/null.o \
gfx/null.o
screenshot.o
JOYCONFIG_OBJ := tools/retroarch-joyconfig.o \
conf/config_file.o \
@ -50,7 +51,7 @@ endif
ifneq ($(findstring Linux,$(OS)),)
LIBS += -lrt
OBJ += input/linuxraw_input.o
OBJ += input/linuxraw_input.o input/linuxraw_joypad.o
endif
ifeq ($(HAVE_THREADS), 1)
@ -139,54 +140,61 @@ ifeq ($(SCALER_PERF), 1)
endif
ifeq ($(HAVE_SDL), 1)
OBJ += gfx/sdl_gfx.o input/sdl_input.o input/sdl_joypad.o audio/sdl_audio.o fifo_buffer.o
OBJ += gfx/scaler/scaler.o gfx/scaler/pixconv.o gfx/scaler/scaler_int.o gfx/scaler/filter.o
else ifeq ($(HAVE_FFMPEG), 1)
OBJ += gfx/scaler/scaler.o gfx/scaler/pixconv.o gfx/scaler/scaler_int.o gfx/scaler/filter.o
endif
ifeq ($(HAVE_SDL), 1)
OBJ += gfx/sdl_gfx.o input/sdl_input.o input/sdl_joypad.o audio/sdl_audio.o
DEFINES += $(SDL_CFLAGS) $(BSD_LOCAL_INC)
LIBS += $(SDL_LIBS)
ifeq ($(HAVE_OPENGL), 1)
OBJ += gfx/gl.o gfx/gfx_context.o gfx/fonts/freetype.o gfx/math/matrix.o
ifeq ($(OSX), 1)
LIBS += -framework OpenGL
else
ifeq ($(HAVE_KMS), 1)
OBJ += gfx/context/drm_egl_ctx.o
DEFINES += $(GBM_CFLAGS) $(DRM_CFLAGS) $(EGL_CFLAGS)
LIBS += $(GBM_LIBS) $(DRM_LIBS) $(EGL_LIBS)
endif
ifeq ($(HAVE_VIDEOCORE), 1)
OBJ += gfx/context/vc_egl_ctx.o
# videocore's libs set later
endif
ifeq ($(HAVE_X11), 1)
ifeq ($(HAVE_EGL), 1)
OBJ += gfx/context/xegl_ctx.o
DEFINES += $(EGL_CFLAGS)
LIBS += $(EGL_LIBS)
endif
endif
endif
OBJ += gfx/context/sdl_ctx.o
ifeq ($(HAVE_GLES), 1)
LIBS += -lGLESv2
DEFINES += -DHAVE_OPENGLES -DHAVE_OPENGLES2
else
LIBS += -lGL
endif
endif
ifeq ($(HAVE_OPENGL), 1)
OBJ += gfx/gl.o gfx/gfx_context.o gfx/fonts/freetype.o gfx/math/matrix.o
ifeq ($(OSX), 1)
LIBS += -framework OpenGL
else
ifeq ($(HAVE_KMS), 1)
OBJ += gfx/context/drm_egl_ctx.o
DEFINES += $(GBM_CFLAGS) $(DRM_CFLAGS) $(EGL_CFLAGS)
LIBS += $(GBM_LIBS) $(DRM_LIBS) $(EGL_LIBS)
endif
ifeq ($(HAVE_VIDEOCORE), 1)
OBJ += gfx/context/vc_egl_ctx.o
# videocore's libs set later
endif
ifeq ($(HAVE_X11), 1)
ifeq ($(HAVE_EGL), 1)
OBJ += gfx/context/xegl_ctx.o
DEFINES += $(EGL_CFLAGS)
LIBS += $(EGL_LIBS)
endif
endif
endif
ifeq ($(HAVE_VG), 1)
OBJ += gfx/vg.o gfx/math/matrix_3x3.o
DEFINES += $(VG_CFLAGS)
LIBS += $(VG_LIBS)
ifeq ($(HAVE_GLES), 1)
LIBS += -lGLESv2
DEFINES += -DHAVE_OPENGLES -DHAVE_OPENGLES2
else
LIBS += -lGL
endif
endif
ifeq ($(HAVE_VG), 1)
OBJ += gfx/vg.o gfx/math/matrix_3x3.o
DEFINES += $(VG_CFLAGS)
LIBS += $(VG_LIBS)
endif
ifeq ($(HAVE_VIDEOCORE), 1)
LIBS += -lOpenVG -lGLESv2 -lEGL -lbcm_host -lvcos -lvchiq_arm
endif

View File

@ -14,6 +14,7 @@
*/
#include "gfx_context.h"
#include <string.h>
#ifdef HAVE_CONFIG_H
#include "../config.h"

View File

@ -26,7 +26,7 @@ static const rarch_joypad_driver_t *joypad_drivers[] = {
#ifdef HAVE_DINPUT
&dinput_joypad,
#endif
#if defined(__linux) && 0
#ifdef __linux
&linuxraw_joypad,
#endif
#ifdef HAVE_SDL

View File

@ -17,7 +17,6 @@
#include "../driver.h"
#include "SDL.h"
#include "../boolean.h"
#include "../general.h"
#include <stdint.h>

View File

@ -90,7 +90,7 @@ check_pkgconf PULSE libpulse
check_lib COREAUDIO "-framework AudioUnit" AudioUnitInitialize
check_pkgconf SDL sdl 1.2.10 "Cannot find SDL library."
check_pkgconf SDL sdl 1.2.10
# On some distros, -lCg doesn't link against -lstdc++ it seems ...
if [ "$HAVE_OPENGL" != 'no' ]; then
@ -100,7 +100,9 @@ else
HAVE_CG='no'
fi
[ "$HAVE_SDL" = "no" ] && HAVE_SDL_IMAGE=no
check_pkgconf SDL_IMAGE SDL_image
check_pkgconf LIBPNG libpng 1.5
if [ "$HAVE_THREADS" != 'no' ]; then

View File

@ -1,4 +1,5 @@
HAVE_DYNAMIC=yes # Disable dynamic loading of libretro library
HAVE_SDL=auto # SDL support
HAVE_LIBRETRO= # libretro library used
HAVE_THREADS=auto # Threading support
HAVE_FFMPEG=auto # Enable FFmpeg recording support