From: Vadim Zeitlin Date: Wed, 7 Mar 2007 22:09:57 +0000 (+0000) Subject: add checks for GTK+ 2.10 (part of patch 1661851) X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/a48b659563cbb93db2affb995fb4e0711df16d21 add checks for GTK+ 2.10 (part of patch 1661851) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44646 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/configure b/configure index c74780ba1f..1f80a10f05 100755 --- a/configure +++ b/configure @@ -13766,17 +13766,17 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $bakefile_cv_c_compiler___INTEL_COMPILER" >&5 echo "${ECHO_T}$bakefile_cv_c_compiler___INTEL_COMPILER" >&6; } - if test "x$bakefile_cv_c_compiler___INTEL_COMPILER" = "xyes"; then - :; INTELCC=yes - else - :; - fi 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 "x$bakefile_cv_c_compiler___INTEL_COMPILER" = "xyes"; then + :; INTELCC=yes + else + :; + fi if test "x$GCC" != "xyes"; then @@ -14277,17 +14277,17 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $bakefile_cv_c_compiler__SGI_COMPILER_VERSION" >&5 echo "${ECHO_T}$bakefile_cv_c_compiler__SGI_COMPILER_VERSION" >&6; } - if test "x$bakefile_cv_c_compiler__SGI_COMPILER_VERSION" = "xyes"; then - :; SGICC=yes - else - :; - fi 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 "x$bakefile_cv_c_compiler__SGI_COMPILER_VERSION" = "xyes"; then + :; SGICC=yes + else + :; + fi ;; @@ -14357,17 +14357,17 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $bakefile_cv_c_compiler___HP_cc" >&5 echo "${ECHO_T}$bakefile_cv_c_compiler___HP_cc" >&6; } - if test "x$bakefile_cv_c_compiler___HP_cc" = "xyes"; then - :; HPCC=yes - else - :; - fi 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 "x$bakefile_cv_c_compiler___HP_cc" = "xyes"; then + :; HPCC=yes + else + :; + fi ;; @@ -14437,17 +14437,17 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $bakefile_cv_c_compiler___DECC" >&5 echo "${ECHO_T}$bakefile_cv_c_compiler___DECC" >&6; } - if test "x$bakefile_cv_c_compiler___DECC" = "xyes"; then - :; COMPAQCC=yes - else - :; - fi 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 "x$bakefile_cv_c_compiler___DECC" = "xyes"; then + :; COMPAQCC=yes + else + :; + fi ;; @@ -14517,17 +14517,17 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $bakefile_cv_c_compiler___SUNPRO_C" >&5 echo "${ECHO_T}$bakefile_cv_c_compiler___SUNPRO_C" >&6; } - if test "x$bakefile_cv_c_compiler___SUNPRO_C" = "xyes"; then - :; SUNCC=yes - else - :; - fi 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 "x$bakefile_cv_c_compiler___SUNPRO_C" = "xyes"; then + :; SUNCC=yes + else + :; + fi ;; @@ -15412,17 +15412,17 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $bakefile_cv_cxx_compiler___INTEL_COMPILER" >&5 echo "${ECHO_T}$bakefile_cv_cxx_compiler___INTEL_COMPILER" >&6; } - if test "x$bakefile_cv_cxx_compiler___INTEL_COMPILER" = "xyes"; then - :; INTELCXX=yes - else - :; - fi 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 "x$bakefile_cv_c_compiler___INTEL_COMPILER" = "xyes"; then + :; INTELCXX=yes + else + :; + fi if test "x$GCXX" != "xyes"; then @@ -15923,17 +15923,17 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $bakefile_cv_cxx_compiler__SGI_COMPILER_VERSION" >&5 echo "${ECHO_T}$bakefile_cv_cxx_compiler__SGI_COMPILER_VERSION" >&6; } - if test "x$bakefile_cv_cxx_compiler__SGI_COMPILER_VERSION" = "xyes"; then - :; SGICXX=yes - else - :; - fi 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 "x$bakefile_cv_c_compiler__SGI_COMPILER_VERSION" = "xyes"; then + :; SGICXX=yes + else + :; + fi ;; @@ -16003,17 +16003,17 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $bakefile_cv_cxx_compiler___HP_aCC" >&5 echo "${ECHO_T}$bakefile_cv_cxx_compiler___HP_aCC" >&6; } - if test "x$bakefile_cv_cxx_compiler___HP_aCC" = "xyes"; then - :; HPCXX=yes - else - :; - fi 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 "x$bakefile_cv_c_compiler___HP_aCC" = "xyes"; then + :; HPCXX=yes + else + :; + fi ;; @@ -16083,17 +16083,17 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $bakefile_cv_cxx_compiler___DECCXX" >&5 echo "${ECHO_T}$bakefile_cv_cxx_compiler___DECCXX" >&6; } - if test "x$bakefile_cv_cxx_compiler___DECCXX" = "xyes"; then - :; COMPAQCXX=yes - else - :; - fi 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 "x$bakefile_cv_c_compiler___DECCXX" = "xyes"; then + :; COMPAQCXX=yes + else + :; + fi ;; @@ -16163,17 +16163,17 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $bakefile_cv_cxx_compiler___SUNPRO_CC" >&5 echo "${ECHO_T}$bakefile_cv_cxx_compiler___SUNPRO_CC" >&6; } - if test "x$bakefile_cv_cxx_compiler___SUNPRO_CC" = "xyes"; then - :; SUNCXX=yes - else - :; - fi 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 "x$bakefile_cv_c_compiler___SUNPRO_CC" = "xyes"; then + :; SUNCXX=yes + else + :; + fi ;; @@ -29963,8 +29963,9 @@ fi - { echo "$as_me:$LINENO: checking if GTK+ is version >= 2.6" >&5 -echo $ECHO_N "checking if GTK+ is version >= 2.6... $ECHO_C" >&6; } + + { echo "$as_me:$LINENO: checking if GTK+ is version >= 2.10" >&5 +echo $ECHO_N "checking if GTK+ is version >= 2.10... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF @@ -29978,8 +29979,8 @@ int main () { - #if !GTK_CHECK_VERSION(2,6,0) - Not GTK+ 2.6 + #if !GTK_CHECK_VERSION(2,10,0) + Not GTK+ 2.10 #endif ; @@ -30004,6 +30005,10 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 test ! -s conftest.err } && test -s conftest.$ac_objext; then + cat >>confdefs.h <<\_ACEOF +#define __WXGTK210__ 1 +_ACEOF + cat >>confdefs.h <<\_ACEOF #define __WXGTK26__ 1 _ACEOF @@ -30014,7 +30019,7 @@ _ACEOF { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } - ac_wxgtk26=1 + ac_wxgtk210=1 else echo "$as_me: failed program was:" >&5 @@ -30023,31 +30028,99 @@ sed 's/^/| /' conftest.$ac_ext >&5 { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } - ac_wxgtk26=0 + ac_wxgtk210=0 + +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + + if test "$ac_wxgtk210" = 0; then + { echo "$as_me:$LINENO: checking if GTK+ is version >= 2.6" >&5 +echo $ECHO_N "checking if GTK+ is version >= 2.6... $ECHO_C" >&6; } + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + + #include + +int +main () +{ + + #if !GTK_CHECK_VERSION(2,6,0) + Not GTK+ 2.6 + #endif + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 + (eval "$ac_compile") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + + cat >>confdefs.h <<\_ACEOF +#define __WXGTK26__ 1 +_ACEOF + + cat >>confdefs.h <<\_ACEOF +#define __WXGTK24__ 1 +_ACEOF + + { echo "$as_me:$LINENO: result: yes" >&5 +echo "${ECHO_T}yes" >&6; } + ac_wxgtk26=1 + +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + + { echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6; } + ac_wxgtk26=0 fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi if test "$ac_wxgtk26" = 0; then - { echo "$as_me:$LINENO: checking if GTK+ is version >= 2.4" >&5 + { echo "$as_me:$LINENO: checking if GTK+ is version >= 2.4" >&5 echo $ECHO_N "checking if GTK+ is version >= 2.4... $ECHO_C" >&6; } - cat >conftest.$ac_ext <<_ACEOF + cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ - #include + #include int main () { - #if !GTK_CHECK_VERSION(2,4,0) - Not GTK+ 2.4 - #endif + #if !GTK_CHECK_VERSION(2,4,0) + Not GTK+ 2.4 + #endif ; return 0; @@ -30071,11 +30144,11 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 test ! -s conftest.err } && test -s conftest.$ac_objext; then - cat >>confdefs.h <<\_ACEOF + cat >>confdefs.h <<\_ACEOF #define __WXGTK24__ 1 _ACEOF - { echo "$as_me:$LINENO: result: yes" >&5 + { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } else @@ -30083,7 +30156,7 @@ else sed 's/^/| /' conftest.$ac_ext >&5 - { echo "$as_me:$LINENO: result: no" >&5 + { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi @@ -48433,9 +48506,13 @@ fi if test "x$SUNCXX" = "xyes"; then - AR=${AR:-"$CXX"} + AR=$CXX + AROPTIONS="-xar -o" + + elif test "x$SGICC" = "xyes"; then + AR=$CXX + AROPTIONS="-ar -o" - AROPTIONS=${AROPTIONS:-"-xar -o"} else if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. @@ -48831,10 +48908,7 @@ echo "${ECHO_T}$bakefile_cv_prog_makeisgnu" >&6; } PLATFORM_BEOS=1 ;; * ) - { { echo "$as_me:$LINENO: error: Unknown platform: $BAKEFILE_FORCE_PLATFORM" >&5 -echo "$as_me: error: Unknown platform: $BAKEFILE_FORCE_PLATFORM" >&2;} - { (exit 1); exit 1; }; } - ;; + ;; esac fi @@ -49797,7 +49871,10 @@ EOF ;; *) - esac + { { echo "$as_me:$LINENO: error: unknown system type $BAKEFILE_HOST." >&5 +echo "$as_me: error: unknown system type $BAKEFILE_HOST." >&2;} + { (exit 1); exit 1; }; } + esac if test "x$PIC_FLAG" != "x" ; then PIC_FLAG="$PIC_FLAG -DPIC" @@ -50221,10 +50298,10 @@ fi - BAKEFILE_BAKEFILE_M4_VERSION="0.2.1" + BAKEFILE_BAKEFILE_M4_VERSION="0.2.2" -BAKEFILE_AUTOCONF_INC_M4_VERSION="0.2.1" +BAKEFILE_AUTOCONF_INC_M4_VERSION="0.2.2" diff --git a/configure.in b/configure.in index ccdd99f63c..4de2bbfc04 100644 --- a/configure.in +++ b/configure.in @@ -3158,45 +3158,70 @@ libraries returned by 'pkg-config gtk+-2.0 --libs' or 'gtk-config [AC_DEFINE(NEED_GTK_ICON_SIZE_LOOKUP)], [#include ]) - dnl test if we have at least GTK+ 2.6: - AC_MSG_CHECKING([if GTK+ is version >= 2.6]) + + dnl test if we have at least GTK+ 2.10: + AC_MSG_CHECKING([if GTK+ is version >= 2.10]) AC_TRY_COMPILE([ #include ], [ - #if !GTK_CHECK_VERSION(2,6,0) - Not GTK+ 2.6 + #if !GTK_CHECK_VERSION(2,10,0) + Not GTK+ 2.10 #endif ], [ + AC_DEFINE(__WXGTK210__) AC_DEFINE(__WXGTK26__) AC_DEFINE(__WXGTK24__) AC_MSG_RESULT([yes]) - ac_wxgtk26=1 + ac_wxgtk210=1 ], [ AC_MSG_RESULT([no]) - ac_wxgtk26=0 + ac_wxgtk210=0 ]) + if test "$ac_wxgtk210" = 0; then + dnl test if we have at least GTK+ 2.6: + AC_MSG_CHECKING([if GTK+ is version >= 2.6]) + AC_TRY_COMPILE([ + #include + ], + [ + #if !GTK_CHECK_VERSION(2,6,0) + Not GTK+ 2.6 + #endif + ], + [ + AC_DEFINE(__WXGTK26__) + AC_DEFINE(__WXGTK24__) + AC_MSG_RESULT([yes]) + ac_wxgtk26=1 + ], + [ + AC_MSG_RESULT([no]) + ac_wxgtk26=0 + ]) + fi + if test "$ac_wxgtk26" = 0; then - dnl test if we have at least GTK+ 2.4: - AC_MSG_CHECKING([if GTK+ is version >= 2.4]) - AC_TRY_COMPILE([ - #include - ], - [ - #if !GTK_CHECK_VERSION(2,4,0) - Not GTK+ 2.4 - #endif - ], - [ - AC_DEFINE(__WXGTK24__) - AC_MSG_RESULT([yes]) - ], - [ - AC_MSG_RESULT([no]) - ]) + dnl test if we have at least GTK+ 2.4: + AC_MSG_CHECKING([if GTK+ is version >= 2.4]) + AC_TRY_COMPILE([ + #include + ], + [ + #if !GTK_CHECK_VERSION(2,4,0) + Not GTK+ 2.4 + #endif + ], + [ + AC_DEFINE(__WXGTK24__) + AC_MSG_RESULT([yes]) + ], + [ + AC_MSG_RESULT([no]) + ]) fi CFLAGS="$save_CFLAGS" diff --git a/setup.h.in b/setup.h.in index 65f3c2785c..daff8f50b8 100644 --- a/setup.h.in +++ b/setup.h.in @@ -68,6 +68,9 @@ /* Define this if your version of GTK+ is greater than 2.6 */ #undef __WXGTK26__ +/* Define this if your version of GTK+ is greater than 2.10 */ +#undef __WXGTK210__ + /* Define this if you want to use GPE features */ #undef __WXGPE__ diff --git a/setup.h_vms b/setup.h_vms index 2de279f93a..880d14da64 100644 --- a/setup.h_vms +++ b/setup.h_vms @@ -88,6 +88,9 @@ /* Define this if your version of GTK+ is greater than 2.6 */ #define __WXGTK26__ 1 +/* Define this if your version of GTK+ is greater than 2.10 */ +#define __WXGTK210__ 0 + #include typedef pid_t GPid;