Check for functions after including the libraries that they might be in.
authorSam Lantinga <slouken@libsdl.org>
Sat, 10 Jan 2009 22:36:30 +0000
changeset 3014cacb282192a1
parent 3013 8cc00819c8d6
child 3015 adbb7f8afd2d
Check for functions after including the libraries that they might be in.
configure.in
     1.1 --- a/configure.in	Sat Jan 10 21:50:26 2009 +0000
     1.2 +++ b/configure.in	Sat Jan 10 22:36:30 2009 +0000
     1.3 @@ -149,10 +149,13 @@
     1.4      if test x$ac_cv_func_strtod = xyes; then
     1.5          AC_DEFINE(HAVE_STRTOD)
     1.6      fi
     1.7 -    AC_CHECK_FUNCS(malloc calloc realloc free getenv putenv unsetenv qsort abs bcopy memset memcpy memmove strlen strlcpy strlcat strdup _strrev _strupr _strlwr strchr strrchr strstr itoa _ltoa _uitoa _ultoa strtol strtoul _i64toa _ui64toa strtoll strtoull atoi atof strcmp strncmp _stricmp strcasecmp _strnicmp strncasecmp sscanf snprintf vsnprintf copysign cos cosf fabs floor log pow scalbn sin sinf sqrt iconv sigaction setjmp nanosleep)
     1.8 +    AC_CHECK_FUNCS(malloc calloc realloc free getenv putenv unsetenv qsort abs bcopy memset memcpy memmove strlen strlcpy strlcat strdup _strrev _strupr _strlwr strchr strrchr strstr itoa _ltoa _uitoa _ultoa strtol strtoul _i64toa _ui64toa strtoll strtoull atoi atof strcmp strncmp _stricmp strcasecmp _strnicmp strncasecmp sscanf snprintf vsnprintf sigaction setjmp nanosleep)
     1.9  
    1.10 -    AC_CHECK_LIB(m, pow, [EXTRA_LDFLAGS="$EXTRA_LDFLAGS -lm"])
    1.11 -    AC_CHECK_LIB(iconv, libiconv_open, [EXTRA_LDFLAGS="$EXTRA_LDFLAGS -liconv"])
    1.12 +    AC_CHECK_LIB(m, pow, [LIBS="$LIBS -lm"; EXTRA_LDFLAGS="$EXTRA_LDFLAGS -lm"])
    1.13 +    AC_CHECK_FUNCS(copysign cos cosf fabs floor log pow scalbn sin sinf sqrt)
    1.14 +
    1.15 +    AC_CHECK_LIB(iconv, libiconv_open, [LIBS="$LIBS -liconv"; EXTRA_LDFLAGS="$EXTRA_LDFLAGS -liconv"])
    1.16 +    AC_CHECK_FUNCS(iconv)
    1.17  fi
    1.18  
    1.19  if test x$have_inttypes != xyes; then