diff -r c6ce4c89fcea -r 6952b11b7f46 configure --- a/configure Sat Jan 14 13:17:01 2012 -0500 +++ b/configure Sat Jan 14 13:21:19 2012 -0500 @@ -2025,7 +2025,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu -ac_config_headers="$ac_config_headers include/SDL_config.h" +ac_config_headers="$ac_config_headers include/SDL_config_generated.h" cat >>confdefs.h <<\_ACEOF @@ -15525,12 +15525,17 @@ INCLUDE="-I$srcdir/include" if test x$srcdir != x.; then - # Remove SDL_config.h from the source directory, since it's the - # default one, and we want to include the one that we generate. - if test -f $srcdir/include/SDL_config.h; then - rm $srcdir/include/SDL_config.h - fi INCLUDE="-Iinclude $INCLUDE" +elif test -d .hg; then + { { echo "$as_me:$LINENO: error: +*** When building from Mercurial you should configure and build in a + separate directory so you don't clobber SDL_revision.h +" >&5 +echo "$as_me: error: +*** When building from Mercurial you should configure and build in a + separate directory so you don't clobber SDL_revision.h +" >&2;} + { (exit 1); exit 1; }; } fi case "$host" in *-*-cygwin*) @@ -15546,7 +15551,7 @@ # Uncomment the following line if you want to force SDL and applications # built with it to be compiled for a particular architecture. #AX_GCC_ARCHFLAG([no], [BASE_CFLAGS="$BASE_CFLAGS $ax_cv_gcc_archflag]") -BUILD_CFLAGS="$CFLAGS $CPPFLAGS" +BUILD_CFLAGS="$CFLAGS $CPPFLAGS -DGENERATED_CONFIG_H" # The default optimization for SDL 1.3 is -O3 (Bug #31) if test x$orig_CFLAGS = x; then BUILD_CFLAGS=`echo $BUILD_CFLAGS | sed 's/-O2/-O3/'` @@ -28805,7 +28810,7 @@ for ac_config_target in $ac_config_targets do case $ac_config_target in - "include/SDL_config.h") CONFIG_HEADERS="$CONFIG_HEADERS include/SDL_config.h" ;; + "include/SDL_config_generated.h") CONFIG_HEADERS="$CONFIG_HEADERS include/SDL_config_generated.h" ;; "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile:Makefile.in:Makefile.rules" ;; "sdl-config") CONFIG_FILES="$CONFIG_FILES sdl-config" ;;