From: Torsten Giebl
authorRyan C. Gordon <icculus@icculus.org>
Fri, 01 Dec 2006 20:25:03 +0000
changeset 20791ed2155b7ee4
parent 2078 f932ac47a331
child 2080 c611cb0638b2
From: Torsten Giebl
Subject: ALLOCA Patch for SDL-1.2
Newsgroups: gmane.comp.lib.sdl
Date: 2006-10-24 00:31:16 GMT

Hello !

As alloca.h is not available on CYGWIN and MinGW32
it should not be checked there or it should be checked
with -mno-cygwin using.

I am a total configure.in newbie, but i found the way
that things are handled in configure.in pretty bad for the
case CYGWIN with MinGW Mode or not.

Maybe this is not possible but i would like to
have a way to detect at the start for example CYGWIN
and then add. ask if configure was called with --enable-cygwin
for example. --enable-cygwin should be optional and disabled
by default as we want to have MinGW Mode by default.

Only if the user wants it he should be able to use it.

Then the whole configure.in would get add. questions
okay the system is CYGWIN with or without MinGW Mode.

The alloca.h thing for example is only
available under CYGWIN ( without MinGW Mode ).

CU
configure.in
     1.1 --- a/configure.in	Wed Nov 29 10:38:07 2006 +0000
     1.2 +++ b/configure.in	Fri Dec 01 20:25:03 2006 +0000
     1.3 @@ -124,7 +124,14 @@
     1.4      fi
     1.5  
     1.6      dnl Checks for library functions.
     1.7 -    AC_FUNC_ALLOCA
     1.8 +    case "$host" in
     1.9 +    *-*-cygwin* | *-*-mingw32*)
    1.10 +        ;;
    1.11 +    *)
    1.12 +        AC_FUNC_ALLOCA
    1.13 +        ;;
    1.14 +    esac
    1.15 +
    1.16      AC_FUNC_MEMCMP
    1.17      if test x$ac_cv_func_memcmp_working = xyes; then
    1.18          AC_DEFINE(HAVE_MEMCMP)