From 54070045482329b23bd0236adffb199b65fb1d14 Mon Sep 17 00:00:00 2001 From: Bradley Bell Date: Sun, 17 May 2015 02:04:56 -0700 Subject: [PATCH] move i/o defines to cppflags --- Makefile.am | 8 +++++--- arch/carbon/conf.h | 23 ----------------------- arch/cocoa/conf.h | 23 ----------------------- configure.ac | 23 ----------------------- 4 files changed, 5 insertions(+), 72 deletions(-) diff --git a/Makefile.am b/Makefile.am index a03fb55e..a95179c6 100644 --- a/Makefile.am +++ b/Makefile.am @@ -95,7 +95,7 @@ miner_LDADD = $(d2x_LDADD) # Remaining targets are based on d2x_* -d2x_svga_CPPFLAGS = $(d2x_CPPFLAGS) -DSVGA +d2x_svga_CPPFLAGS = $(d2x_CPPFLAGS) -DSVGA -DSVGALIB_INPUT -DSVGALIB_VIDEO d2x_svga_SOURCES = $(d2x_SOURCES) arch/svgalib/event.c arch/svgalib/vid.c arch/svgalib/key.c arch/svgalib/mouse.c arch/svgalib/init.c d2x_svga_LDFLAGS = $(d2x_LDFLAGS) d2x_svga_LDADD = $(d2x_LDADD) -lvga -lvgagl @@ -106,8 +106,10 @@ miner_svga_LDFLAGS = $(d2x_svga_LDFLAGS) miner_svga_LDADD = $(d2x_svga_LDADD) -d2x_sdl_CPPFLAGS = $(d2x_CPPFLAGS) $(SDL_CFLAGS) $(SDLMIXER_CFLAGS) -I$(top_srcdir)/arch/linux/include +_d2x_sdl_CPPFLAGS = $(d2x_CPPFLAGS) $(SDL_CFLAGS) $(SDLMIXER_CFLAGS) -I$(top_srcdir)/arch/linux/include -DSDL_INPUT _d2x_sdl_SOURCES = $(d2x_SOURCES) arch/sdl/event.c arch/sdl/key.c arch/sdl/mouse.c + +d2x_sdl_CPPFLAGS = $(_d2x_sdl_CPPFLAGS) -DSDL_VIDEO d2x_sdl_SOURCES = $(_d2x_sdl_SOURCES) arch/sdl/vid.c texmap/tmapflat.c d2x_sdl_LDFLAGS = $(d2x_LDFLAGS) d2x_sdl_LDADD = $(d2x_LDADD) $(SDL_LIBS) $(SDLIMAGE_LIBS) $(SDLMIXER_LIBS) @@ -162,7 +164,7 @@ miner_sdl_LDADD = $(d2x_sdl_LDADD) # GL target is based on d2x_sdl_*, other than renderer -d2x_gl_CPPFLAGS = $(d2x_sdl_CPPFLAGS) -DOGL +d2x_gl_CPPFLAGS = $(d2x_sdl_CPPFLAGS) -DOGL -DSDL_GL_VIDEO d2x_gl_SOURCES = $(_d2x_sdl_SOURCES) arch/ogl/vid.c arch/ogl/ogl.c arch/ogl/sdlgl.c d2x_gl_LDFLAGS = $(d2x_sdl_LDFLAGS) d2x_gl_LDADD = $(d2x_sdl_LDADD) diff --git a/arch/carbon/conf.h b/arch/carbon/conf.h index d3a6d236..28f3f7cd 100755 --- a/arch/carbon/conf.h +++ b/arch/carbon/conf.h @@ -157,26 +157,3 @@ #endif // OS 9/X -#ifdef __unix__ -# ifdef SVGA -# define SVGALIB_INPUT 1 -# define SVGALIB_VIDEO 1 -# else -# define SDL_INPUT 1 -# ifdef OGL -# define SDL_GL_VIDEO 1 -# else -# define SDL_VIDEO 1 -# endif -# endif -#endif - -#ifdef macintosh -# define SDL_INPUT 1 -# ifdef OGL -# define SDL_GL_VIDEO 1 -# else -# define SDL_VIDEO 1 -# endif -#endif - diff --git a/arch/cocoa/conf.h b/arch/cocoa/conf.h index 17203da7..0329772d 100644 --- a/arch/cocoa/conf.h +++ b/arch/cocoa/conf.h @@ -151,26 +151,3 @@ #define __unix__ /* since we're doing a unix-style compilation... */ #endif -#ifdef __unix__ -# ifdef SVGA -# define SVGALIB_INPUT 1 -# define SVGALIB_VIDEO 1 -# else -# define SDL_INPUT 1 -# ifdef OGL -# define SDL_GL_VIDEO 1 -# else -# define SDL_VIDEO 1 -# endif -# endif -#endif - -#ifdef _WIN32 -# define SDL_INPUT 1 -# ifdef OGL -# define SDL_GL_VIDEO 1 -# else -# define SDL_VIDEO 1 -# endif -#endif - diff --git a/configure.ac b/configure.ac index 01b8bf64..93deb863 100644 --- a/configure.ac +++ b/configure.ac @@ -327,29 +327,6 @@ AH_BOTTOM([ #if defined(__APPLE__) && defined(__MACH__) #define __unix__ /* since we're doing a unix-style compilation... */ -#endif - -#ifdef __unix__ -# ifdef SVGA -# define SVGALIB_INPUT 1 -# define SVGALIB_VIDEO 1 -# else -# define SDL_INPUT 1 -# ifdef OGL -# define SDL_GL_VIDEO 1 -# else -# define SDL_VIDEO 1 -# endif -# endif -#endif - -#ifdef _WIN32 -# define SDL_INPUT 1 -# ifdef OGL -# define SDL_GL_VIDEO 1 -# else -# define SDL_VIDEO 1 -# endif #endif ]) -- 2.39.2