If SDL is not used, just don't compile those files, instead of

compiling (after preprocessing) empty files.



git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@3521 8092fc87-c524-0410-9efc-e669fe64eaf9
This commit is contained in:
Meep-Eep
2010-01-25 21:20:59 +00:00
parent 6d1d492fac
commit df4204b16b
17 changed files with 14 additions and 46 deletions
+4 -1
View File
@@ -199,6 +199,7 @@ uqm_prepare_config()
CHOICE_graphics_OPTION_pure_ACTION='graphics_pure_action' CHOICE_graphics_OPTION_pure_ACTION='graphics_pure_action'
graphics_pure_action() { graphics_pure_action() {
CFLAGS="$CFLAGS -DGFXMODULE_SDL" CFLAGS="$CFLAGS -DGFXMODULE_SDL"
GFXMODULE_SDL=1
HAVE_OPENGL=0 HAVE_OPENGL=0
} }
CHOICE_graphics_OPTION_opengl_TITLE="Include OpenGL graphics support" CHOICE_graphics_OPTION_opengl_TITLE="Include OpenGL graphics support"
@@ -206,6 +207,7 @@ uqm_prepare_config()
CHOICE_graphics_OPTION_opengl_PRECOND="have_library opengl" CHOICE_graphics_OPTION_opengl_PRECOND="have_library opengl"
graphics_opengl_action() { graphics_opengl_action() {
CFLAGS="$CFLAGS -DGFXMODULE_SDL -DHAVE_OPENGL" CFLAGS="$CFLAGS -DGFXMODULE_SDL -DHAVE_OPENGL"
GFXMODULE_SDL=1
HAVE_OPENGL=1 HAVE_OPENGL=1
use_library opengl use_library opengl
} }
@@ -435,7 +437,8 @@ uqm_process_config() {
PREPROC_OBJC MKDEP_OBJC COMPILE_OBJC \ PREPROC_OBJC MKDEP_OBJC COMPILE_OBJC \
MAKE ECHON SED DEBUG JOYSTICK NETPLAY \ MAKE ECHON SED DEBUG JOYSTICK NETPLAY \
OGGVORBIS SOUNDMODULE USE_INTERNAL_MIKMOD \ OGGVORBIS SOUNDMODULE USE_INTERNAL_MIKMOD \
HAVE_OPENGL HAVE_GETOPT_LONG HAVE_REGEX_H_FLAG \ GFXMODULE_SDL HAVE_OPENGL \
HAVE_GETOPT_LONG HAVE_REGEX_H_FLAG \
USE_ZIP_IO USE_PLATFORM_ACCEL THREADLIB USE_WINSOCK \ USE_ZIP_IO USE_PLATFORM_ACCEL THREADLIB USE_WINSOCK \
INSTALL_LIBDIR INSTALL_BINDIR INSTALL_SHAREDIR \ INSTALL_LIBDIR INSTALL_BINDIR INSTALL_SHAREDIR \
REZ WINDRES $HAVE_SYMBOLS" REZ WINDRES $HAVE_SYMBOLS"
+6 -1
View File
@@ -1,5 +1,10 @@
uqm_SUBDIRS="sdl" uqm_SUBDIRS=
uqm_CFILES="boxint.c clipline.c cmap.c context.c drawable.c filegfx.c uqm_CFILES="boxint.c clipline.c cmap.c context.c drawable.c filegfx.c
bbox.c dcqueue.c gfxload.c bbox.c dcqueue.c gfxload.c
font.c frame.c gfx_common.c intersec.c loaddisp.c font.c frame.c gfx_common.c intersec.c loaddisp.c
pixmap.c resgfx.c tfb_draw.c tfb_prim.c widgets.c" pixmap.c resgfx.c tfb_draw.c tfb_prim.c widgets.c"
if [ -n "$uqm_GFXMODULE_SDL" ]; then
uqm_SUBDIRS="$uqm_SUBDIRS sdl"
fi
-3
View File
@@ -14,8 +14,6 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/ */
#ifdef GFXMODULE_SDL
#include "libs/graphics/sdl/sdl_common.h" #include "libs/graphics/sdl/sdl_common.h"
#include "types.h" #include "types.h"
#include "scalers.h" #include "scalers.h"
@@ -260,4 +258,3 @@ SCALE_(BiAdaptFilter) (SDL_Surface *src, SDL_Surface *dst, SDL_Rect *r)
SCALE_(PlatDone) (); SCALE_(PlatDone) ();
} }
#endif /* GFXMODULE_SDL */
+1 -3
View File
@@ -14,8 +14,6 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/ */
#ifdef GFXMODULE_SDL
#include "port.h" #include "port.h"
#include "libs/platform.h" #include "libs/platform.h"
@@ -101,4 +99,4 @@ Scale_3DNow_PrepPlatform (const SDL_PixelFormat* fmt)
#endif /* NO_IMPROVEMENT */ #endif /* NO_IMPROVEMENT */
#endif /* MMX_ASM */ #endif /* MMX_ASM */
#endif /* GFXMODULE_SDL */
+1 -3
View File
@@ -14,8 +14,6 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/ */
#ifdef GFXMODULE_SDL
#include "port.h" #include "port.h"
#include "libs/platform.h" #include "libs/platform.h"
@@ -135,4 +133,4 @@ Scale_MMX_PrepPlatform (const SDL_PixelFormat* fmt)
#endif /* MMX_ASM */ #endif /* MMX_ASM */
#endif /* GFXMODULE_SDL */
+1 -3
View File
@@ -14,8 +14,6 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/ */
#ifdef GFXMODULE_SDL
#include "port.h" #include "port.h"
#include "libs/platform.h" #include "libs/platform.h"
@@ -99,4 +97,4 @@ Scale_SSE_PrepPlatform (const SDL_PixelFormat* fmt)
#endif #endif
#endif /* MMX_ASM */ #endif /* MMX_ASM */
#endif /* GFXMODULE_SDL */
-3
View File
@@ -21,8 +21,6 @@
// When this file is built standalone is produces a plain C version // When this file is built standalone is produces a plain C version
// Also #included by 2xscalers_mmx.c for an MMX version // Also #included by 2xscalers_mmx.c for an MMX version
#ifdef GFXMODULE_SDL
#include "libs/graphics/sdl/sdl_common.h" #include "libs/graphics/sdl/sdl_common.h"
#include "types.h" #include "types.h"
#include "scalers.h" #include "scalers.h"
@@ -532,4 +530,3 @@ SCALE_(BiAdaptAdvFilter) (SDL_Surface *src, SDL_Surface *dst, SDL_Rect *r)
SCALE_(PlatDone) (); SCALE_(PlatDone) ();
} }
#endif /* GFXMODULE_SDL */
-3
View File
@@ -19,8 +19,6 @@
// When this file is built standalone is produces a plain C version // When this file is built standalone is produces a plain C version
// Also #included by 2xscalers_mmx.c for an MMX version // Also #included by 2xscalers_mmx.c for an MMX version
#ifdef GFXMODULE_SDL
#include "libs/graphics/sdl/sdl_common.h" #include "libs/graphics/sdl/sdl_common.h"
#include "types.h" #include "types.h"
#include "scalers.h" #include "scalers.h"
@@ -112,4 +110,3 @@ SCALE_(BilinearFilter) (SDL_Surface *src, SDL_Surface *dst, SDL_Rect *r)
SCALE_(PlatDone) (); SCALE_(PlatDone) ();
} }
#endif /* GFXMODULE_SDL */
-3
View File
@@ -27,8 +27,6 @@
// When this file is built standalone is produces a plain C version // When this file is built standalone is produces a plain C version
// Also #included by 2xscalers_mmx.c for an MMX version // Also #included by 2xscalers_mmx.c for an MMX version
#ifdef GFXMODULE_SDL
#include "libs/graphics/sdl/sdl_common.h" #include "libs/graphics/sdl/sdl_common.h"
#include "types.h" #include "types.h"
#include "scalers.h" #include "scalers.h"
@@ -2888,4 +2886,3 @@ SCALE_(HqFilter) (SDL_Surface *src, SDL_Surface *dst, SDL_Rect *r)
SCALE_(PlatDone) (); SCALE_(PlatDone) ();
} }
#endif /* GFXMODULE_SDL */
-3
View File
@@ -19,8 +19,6 @@
// When this file is built standalone is produces a plain C version // When this file is built standalone is produces a plain C version
// Also #included by 2xscalers_mmx.c for an MMX version // Also #included by 2xscalers_mmx.c for an MMX version
#ifdef GFXMODULE_SDL
#include "libs/graphics/sdl/sdl_common.h" #include "libs/graphics/sdl/sdl_common.h"
#include "types.h" #include "types.h"
#include "scalers.h" #include "scalers.h"
@@ -207,4 +205,3 @@ SCALE_(Nearest) (SDL_Surface *src, SDL_Surface *dst, SDL_Rect *r)
SCALE_(PlatDone) (); SCALE_(PlatDone) ();
} }
#endif /* GFXMODULE_SDL */
+1 -1
View File
@@ -16,7 +16,7 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/ */
#if defined (GFXMODULE_SDL) && defined (HAVE_OPENGL) #ifdef HAVE_OPENGL
#include "libs/graphics/sdl/opengl.h" #include "libs/graphics/sdl/opengl.h"
#include "libs/graphics/bbox.h" #include "libs/graphics/bbox.h"
-3
View File
@@ -16,8 +16,6 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/ */
#ifdef GFXMODULE_SDL
#include "port.h" #include "port.h"
#include "sdl_common.h" #include "sdl_common.h"
#include "primitives.h" #include "primitives.h"
@@ -629,4 +627,3 @@ clip_blt_rects(SDL_Rect *src_r, SDL_Rect *dst_r, const SDL_Rect *clip_r)
return 1; return 1;
} }
#endif
-3
View File
@@ -15,8 +15,6 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/ */
#ifdef GFXMODULE_SDL
#include "pure.h" #include "pure.h"
#include "libs/graphics/bbox.h" #include "libs/graphics/bbox.h"
#include "scalers.h" #include "scalers.h"
@@ -475,4 +473,3 @@ Scale_PerfTest (void)
SDL_UnlockSurface (SDL_Screen); SDL_UnlockSurface (SDL_Screen);
} }
#endif
-3
View File
@@ -9,8 +9,6 @@
*/ */
#ifdef GFXMODULE_SDL
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
#include "libs/memlib.h" #include "libs/memlib.h"
@@ -1025,4 +1023,3 @@ SDL_Surface *zoomSurface(SDL_Surface * src, double zoomx, double zoomy, int smoo
return (rz_dst); return (rz_dst);
} }
#endif
-3
View File
@@ -14,8 +14,6 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/ */
#ifdef GFXMODULE_SDL
#include "types.h" #include "types.h"
#include "libs/graphics/sdl/sdl_common.h" #include "libs/graphics/sdl/sdl_common.h"
#include "libs/platform.h" #include "libs/platform.h"
@@ -286,4 +284,3 @@ Scale_PrepPlatform (int flags, const SDL_PixelFormat* fmt)
return fdef->func; return fdef->func;
} }
#endif
-4
View File
@@ -16,8 +16,6 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/ */
#ifdef GFXMODULE_SDL
#include "sdl_common.h" #include "sdl_common.h"
#include "opengl.h" #include "opengl.h"
#include "pure.h" #include "pure.h"
@@ -607,5 +605,3 @@ TFB_SetGamma (float gamma)
} }
} }
#endif
-3
View File
@@ -20,8 +20,6 @@
// When this file is built standalone is produces a plain C version // When this file is built standalone is produces a plain C version
// Also #included by 2xscalers_mmx.c for an MMX version // Also #included by 2xscalers_mmx.c for an MMX version
#ifdef GFXMODULE_SDL
#include "libs/graphics/sdl/sdl_common.h" #include "libs/graphics/sdl/sdl_common.h"
#include "types.h" #include "types.h"
#include "scalers.h" #include "scalers.h"
@@ -155,4 +153,3 @@ SCALE_(TriScanFilter) (SDL_Surface *src, SDL_Surface *dst, SDL_Rect *r)
SCALE_(PlatDone) (); SCALE_(PlatDone) ();
} }
#endif /* GFXMODULE_SDL */