]> git.saurik.com Git - wxWidgets.git/commitdiff
Need to do tests for compiler version (to determine C++ libs needed to
authorStefan Neis <Stefan.Neis@t-online.de>
Sun, 7 May 2006 14:43:41 +0000 (14:43 +0000)
committerStefan Neis <Stefan.Neis@t-online.de>
Sun, 7 May 2006 14:43:41 +0000 (14:43 +0000)
        successfully link C++ core) in C mode on OS/2.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@39103 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

configure
configure.in

index 75a8f7c5c49e35f08855f55880016a976468cc73..ea9d951b238831accfb2f0b51893d5c8dee4abd6 100755 (executable)
--- a/configure
+++ b/configure
@@ -15139,7 +15139,13 @@ esac
 
 case "${host}" in
   *-pc-os2_emx | *-pc-os2-emx )
-                                                      if test "$wxUSE_MOTIF" = 1 -o "$wxUSE_GTK" = 1 -o "$wxUSE_X11" = 1; then
+                                                      ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
+      if test "$wxUSE_MOTIF" = 1 -o "$wxUSE_GTK" = 1 -o "$wxUSE_X11" = 1; then
                               echo "$as_me:$LINENO: checking for drand48 in -lcExt" >&5
 echo $ECHO_N "checking for drand48 in -lcExt... $ECHO_C" >&6
 if test "${ac_cv_lib_cExt_drand48+set}" = set; then
 fi
 echo "$as_me:$LINENO: result: $wx_cv_gccversion" >&5
 echo "${ECHO_T}$wx_cv_gccversion" >&6
+      ac_ext=cc
+ac_cpp='$CXXCPP $CPPFLAGS'
+ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
+
       if test "$wx_cv_gccversion" = "EMX2"; then
           LIBS="$LIBS -lstdcpp"
           LDFLAGS="$LDFLAGS -Zsysv-signals"
index a5e49b32e2bec04158f8552c2b966afb7a1cb9e8..e8e2b4a4a67a9d3f78836b691df396246f89977f 100644 (file)
@@ -1613,6 +1613,7 @@ case "${host}" in
       dnl not "g++/c++".
       dnl ---------------------------------------------------------------------
       dnl (OS/2-only piece)
+      AC_LANG_PUSH(C)
       if test "$wxUSE_MOTIF" = 1 -o "$wxUSE_GTK" = 1 -o "$wxUSE_X11" = 1; then
           dnl More complete Unix emulation for unix-like ports
           dnl by linking in POSIX/2's cExt (if available).
@@ -1656,6 +1657,7 @@ case "${host}" in
               wx_cv_gccversion="EMX2"
           )
       ])
+      AC_LANG_POP
       if test "$wx_cv_gccversion" = "EMX2"; then
           LIBS="$LIBS -lstdcpp"
           LDFLAGS="$LDFLAGS -Zsysv-signals"