Do _not_ test for strcasecmp on OS/2 (where stricmp is the function to be used).
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@25816 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
109
configure.in
109
configure.in
@@ -1464,15 +1464,20 @@ fi dnl not GNU make
|
|||||||
dnl needed for making link to setup.h
|
dnl needed for making link to setup.h
|
||||||
AC_PROG_LN_S
|
AC_PROG_LN_S
|
||||||
|
|
||||||
dnl ---------------------------------------------------------------------------
|
dnl ------------------------------------------------------------------------
|
||||||
dnl When we are using gcc on OS/2, we want to be either using resources (PM)
|
dnl Platform specific tests
|
||||||
dnl or a more complete POSIX emulation for Motif/GTK+/X11
|
dnl ------------------------------------------------------------------------
|
||||||
dnl Moreover we need to link explicitly against either stdcpp.a or stdcxx.a
|
|
||||||
dnl (depending on compiler version), since we are using "gcc", not "g++/c++".
|
|
||||||
dnl ---------------------------------------------------------------------------
|
|
||||||
dnl (OS/2-only piece)
|
|
||||||
case "${host}" in
|
case "${host}" in
|
||||||
*-pc-os2_emx | *-pc-os2-emx )
|
*-pc-os2_emx | *-pc-os2-emx )
|
||||||
|
dnl ---------------------------------------------------------------------
|
||||||
|
dnl When we are using gcc on OS/2, we want to be either using resources
|
||||||
|
dnl (PM) or a more complete POSIX emulation for Motif/GTK+/X11.
|
||||||
|
dnl Moreover we need to link explicitly against either stdcpp.a or
|
||||||
|
dnl stdcxx.a (depending on compiler version), since we are using "gcc",
|
||||||
|
dnl not "g++/c++".
|
||||||
|
dnl ---------------------------------------------------------------------
|
||||||
|
dnl (OS/2-only piece)
|
||||||
if test "$wxUSE_MOTIF" = 1 -o "$wxUSE_GTK" = 1 -o "$wxUSE_X11" = 1; then
|
if test "$wxUSE_MOTIF" = 1 -o "$wxUSE_GTK" = 1 -o "$wxUSE_X11" = 1; then
|
||||||
dnl More complete Unix emulation for unix-like ports
|
dnl More complete Unix emulation for unix-like ports
|
||||||
dnl by linking in POSIX/2's cExt (if available).
|
dnl by linking in POSIX/2's cExt (if available).
|
||||||
@@ -1501,54 +1506,62 @@ case "${host}" in
|
|||||||
else
|
else
|
||||||
LIBS="$LIBS -lstdcxx"
|
LIBS="$LIBS -lstdcxx"
|
||||||
fi
|
fi
|
||||||
|
dnl (end of OS/2-only piece)
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
dnl ---------------------------------------------------------------------
|
||||||
|
dnl look for strcasecmp() in string.h and then strings.h if it's not
|
||||||
|
dnl there. Don't do this on OS/2, where "stricmp" is the function to be
|
||||||
|
dnl used.
|
||||||
|
dnl ---------------------------------------------------------------------
|
||||||
|
dnl (non-OS/2-only piece)
|
||||||
|
|
||||||
|
AC_LANG_SAVE
|
||||||
|
AC_LANG_CPLUSPLUS
|
||||||
|
|
||||||
|
AC_CACHE_CHECK([for strcasecmp() in string.h], ac_cv_string_strcasecmp, [
|
||||||
|
AC_TRY_LINK([
|
||||||
|
#include <string.h>
|
||||||
|
],
|
||||||
|
[
|
||||||
|
strcasecmp("foo", "bar");
|
||||||
|
],
|
||||||
|
ac_cv_string_strcasecmp=yes,
|
||||||
|
ac_cv_string_strcasecmp=no
|
||||||
|
)
|
||||||
|
])
|
||||||
|
|
||||||
|
if test x"$ac_cv_string_strcasecmp" = "xyes"; then
|
||||||
|
AC_DEFINE(HAVE_STRCASECMP_IN_STRING_H)
|
||||||
|
else
|
||||||
|
AC_CACHE_CHECK([for strcasecmp() in strings.h], ac_cv_strings_strcasecmp, [
|
||||||
|
AC_TRY_LINK([
|
||||||
|
#include <strings.h>
|
||||||
|
],
|
||||||
|
[
|
||||||
|
strcasecmp("foo", "bar");
|
||||||
|
],
|
||||||
|
ac_cv_strings_strcasecmp=yes,
|
||||||
|
ac_cv_strings_strcasecmp=no
|
||||||
|
)
|
||||||
|
])
|
||||||
|
|
||||||
|
if test x"$ac_cv_string_strcasecmp" = "xyes"; then
|
||||||
|
AC_DEFINE(HAVE_STRCASECMP_IN_STRINGS_H)
|
||||||
|
else
|
||||||
|
AC_MSG_ERROR([No case-insensitive string comparison function found.])
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
AC_LANG_RESTORE
|
||||||
|
dnl (end of non-OS/2-only piece)
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
dnl (end of OS/2-only piece)
|
|
||||||
|
|
||||||
dnl ------------------------------------------------------------------------
|
dnl ------------------------------------------------------------------------
|
||||||
dnl Check for headers
|
dnl Check for headers
|
||||||
dnl ------------------------------------------------------------------------
|
dnl ------------------------------------------------------------------------
|
||||||
|
|
||||||
dnl look for strcasecmp() in string.h and then strings.h if it's not there
|
|
||||||
AC_LANG_SAVE
|
|
||||||
AC_LANG_CPLUSPLUS
|
|
||||||
|
|
||||||
AC_CACHE_CHECK([for strcasecmp() in string.h], ac_cv_string_strcasecmp, [
|
|
||||||
AC_TRY_LINK([
|
|
||||||
#include <string.h>
|
|
||||||
],
|
|
||||||
[
|
|
||||||
strcasecmp("foo", "bar");
|
|
||||||
],
|
|
||||||
ac_cv_string_strcasecmp=yes,
|
|
||||||
ac_cv_string_strcasecmp=no
|
|
||||||
)
|
|
||||||
])
|
|
||||||
|
|
||||||
if test x"$ac_cv_string_strcasecmp" = "xyes"; then
|
|
||||||
AC_DEFINE(HAVE_STRCASECMP_IN_STRING_H)
|
|
||||||
else
|
|
||||||
AC_CACHE_CHECK([for strcasecmp() in strings.h], ac_cv_strings_strcasecmp, [
|
|
||||||
AC_TRY_LINK([
|
|
||||||
#include <strings.h>
|
|
||||||
],
|
|
||||||
[
|
|
||||||
strcasecmp("foo", "bar");
|
|
||||||
],
|
|
||||||
ac_cv_strings_strcasecmp=yes,
|
|
||||||
ac_cv_strings_strcasecmp=no
|
|
||||||
)
|
|
||||||
])
|
|
||||||
|
|
||||||
if test x"$ac_cv_string_strcasecmp" = "xyes"; then
|
|
||||||
AC_DEFINE(HAVE_STRCASECMP_IN_STRINGS_H)
|
|
||||||
else
|
|
||||||
AC_MSG_ERROR([No case-insensitive string comparison function found.])
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
AC_LANG_RESTORE
|
|
||||||
|
|
||||||
dnl defines HAVE_STDLIB_H
|
dnl defines HAVE_STDLIB_H
|
||||||
AC_CHECK_HEADERS(stdlib.h)
|
AC_CHECK_HEADERS(stdlib.h)
|
||||||
dnl defines HAVE_MALLOC_H
|
dnl defines HAVE_MALLOC_H
|
||||||
|
Reference in New Issue
Block a user