From 12d77bd1dc660bb4401801461fe1b4570a32556f Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Mon, 21 Mar 2016 00:56:50 +0100 Subject: [PATCH] Don't check for Metrowerks compiler in configure under OS X This is just a waste of time, this compiler doesn't exist since many years and has never been used under OS X. --- build/aclocal/bakefile-lang.m4 | 64 +---- build/aclocal/bakefile.m4 | 32 --- configure | 426 --------------------------------- configure.in | 16 -- 4 files changed, 1 insertion(+), 537 deletions(-) diff --git a/build/aclocal/bakefile-lang.m4 b/build/aclocal/bakefile-lang.m4 index a33d61cad4..ad55fa8e2c 100644 --- a/build/aclocal/bakefile-lang.m4 +++ b/build/aclocal/bakefile-lang.m4 @@ -87,17 +87,6 @@ AC_DEFUN([_AC_BAKEFILE_LANG_COMPILER_LATER_THAN], AC_LANG_POP($2) ]) -dnl CodeWarrior Metrowerks compiler defines __MWERKS__ for both C and C++ -AC_DEFUN([AC_BAKEFILE_PROG_MWCC], -[ - _AC_BAKEFILE_LANG_COMPILER(Metrowerks, C, __MWERKS__, MWCC=yes) -]) - -AC_DEFUN([AC_BAKEFILE_PROG_MWCXX], -[ - _AC_BAKEFILE_LANG_COMPILER(Metrowerks, C++, __MWERKS__, MWCXX=yes) -]) - dnl IBM xlC compiler defines __xlC__ for both C and C++ AC_DEFUN([AC_BAKEFILE_PROG_XLCC], [ @@ -190,46 +179,6 @@ AC_DEFUN([AC_BAKEFILE_PROG_COMPAQCXX], _AC_BAKEFILE_LANG_COMPILER(Compaq, C++, __DECCXX, COMPAQCXX=yes) ]) -dnl =========================================================================== -dnl macros to detect specialty compiler options -dnl =========================================================================== - -dnl Figure out if we need to pass -ext o to compiler (MetroWerks) -AC_DEFUN([AC_BAKEFILE_METROWERKS_EXTO], -[AC_CACHE_CHECK([if the _AC_LANG compiler requires -ext o], bakefile_cv_[]_AC_LANG_ABBREV[]_exto, -dnl First create an empty conf test -[AC_LANG_CONFTEST([AC_LANG_PROGRAM()]) -dnl Now remove .o and .c.o or .cc.o -rm -f conftest.$ac_objext conftest.$ac_ext.o -dnl Now compile the test -AS_IF([AC_TRY_EVAL(ac_compile)], -dnl If the test succeeded look for conftest.c.o or conftest.cc.o -[for ac_file in `(ls conftest.* 2>/dev/null)`; do - case $ac_file in - conftest.$ac_ext.o) - bakefile_cv_[]_AC_LANG_ABBREV[]_exto="-ext o" - ;; - *) - ;; - esac -done], -[AC_MSG_FAILURE([cannot figure out if compiler needs -ext o: cannot compile]) -]) dnl AS_IF - -rm -f conftest.$ac_ext.o conftest.$ac_objext conftest.$ac_ext -]) dnl AC_CACHE_CHECK - -if test "x$bakefile_cv_[]_AC_LANG_ABBREV[]_exto" '!=' "x"; then - if test "[]_AC_LANG_ABBREV[]" = "c"; then - CFLAGS="$bakefile_cv_[]_AC_LANG_ABBREV[]_exto $CFLAGS" - fi - if test "[]_AC_LANG_ABBREV[]" = "cxx"; then - CXXFLAGS="$bakefile_cv_[]_AC_LANG_ABBREV[]_exto $CXXFLAGS" - fi -fi -]) dnl AC_DEFUN - - dnl =========================================================================== dnl Macros to do all of the compiler detections as one macro dnl =========================================================================== @@ -253,14 +202,6 @@ AC_DEFUN([_AC_BAKEFILE_PROG_COMPILER], dnl if we're using gcc, we can't be using any of incompatible compilers if test "x$G$1" != "xyes"; then - if test "x$1" = "xC"; then - AC_BAKEFILE_METROWERKS_EXTO - if test "x$bakefile_cv_c_exto" '!=' "x"; then - unset ac_cv_prog_cc_g - _AC_PROG_CC_G - fi - fi - dnl most of these compilers are only used under well-defined OS so dnl don't waste time checking for them on other ones case `uname -s` in @@ -269,10 +210,7 @@ AC_DEFUN([_AC_BAKEFILE_PROG_COMPILER], ;; Darwin) - AC_BAKEFILE_PROG_MW$1 - if test "$MW$1" != "yes"; then - AC_BAKEFILE_PROG_XL$1 - fi + AC_BAKEFILE_PROG_XL$1 ;; IRIX*) diff --git a/build/aclocal/bakefile.m4 b/build/aclocal/bakefile.m4 index d6ac2692e3..2fb069839b 100644 --- a/build/aclocal/bakefile.m4 +++ b/build/aclocal/bakefile.m4 @@ -501,10 +501,6 @@ AC_DEFUN([AC_BAKEFILE_DEPS], DEPSMODE=gcc DEPSFLAG="-MMD" AC_MSG_RESULT([gcc]) - elif test "x$MWCC" = "xyes"; then - DEPSMODE=mwcc - DEPSFLAG="-MM" - AC_MSG_RESULT([mwcc]) elif test "x$SUNCC" = "xyes"; then DEPSMODE=unixcc DEPSFLAG="-xM1" @@ -843,34 +839,6 @@ if test ${D}DEPSMODE = gcc ; then fi exit 0 -elif test ${D}DEPSMODE = mwcc ; then - ${D}* || exit ${D}? - # Run mwcc again with -MM and redirect into the dep file we want - # NOTE: We can't use shift here because we need ${D}* to be valid - prevarg= - for arg in ${D}* ; do - if test "${D}prevarg" = "-o"; then - objfile=${D}arg - else - case "${D}arg" in - -* ) - ;; - * ) - srcfile=${D}arg - ;; - esac - fi - prevarg="${D}arg" - done - - objfilebase=\`basename ${D}objfile\` - builddir=\`dirname ${D}objfile\` - depsdir=${D}builddir/${D}DEPSDIRBASE - mkdir -p ${D}depsdir - - ${D}* ${D}DEPSFLAG >${D}{depsdir}/${D}{objfilebase}.d - exit 0 - elif test ${D}DEPSMODE = unixcc; then ${D}* || exit ${D}? # Run compiler again with deps flag and redirect into the dep file. diff --git a/configure b/configure index 31ed6254ed..639abed9f6 100755 --- a/configure +++ b/configure @@ -13210,144 +13210,6 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu fi if test "x$GCC" != "xyes"; then - if test "xCC" = "xC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler requires -ext o" >&5 -$as_echo_n "checking if the C compiler requires -ext o... " >&6; } -if ${bakefile_cv_c_exto+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest.$ac_ext.o -if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - for ac_file in `(ls conftest.* 2>/dev/null)`; do - case $ac_file in - conftest.$ac_ext.o) - bakefile_cv_c_exto="-ext o" - ;; - *) - ;; - esac -done -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot figure out if compiler needs -ext o: cannot compile -See \`config.log' for more details" "$LINENO" 5; } - -fi -rm -f conftest.$ac_ext.o conftest.$ac_objext conftest.$ac_ext - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $bakefile_cv_c_exto" >&5 -$as_echo "$bakefile_cv_c_exto" >&6; } -if test "x$bakefile_cv_c_exto" '!=' "x"; then - if test "c" = "c"; then - CFLAGS="$bakefile_cv_c_exto $CFLAGS" - fi - if test "c" = "cxx"; then - CXXFLAGS="$bakefile_cv_c_exto $CXXFLAGS" - fi -fi - - if test "x$bakefile_cv_c_exto" '!=' "x"; then - unset ac_cv_prog_cc_g - ac_test_CFLAGS=${CFLAGS+set} -ac_save_CFLAGS=$CFLAGS -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 -$as_echo_n "checking whether $CC accepts -g... " >&6; } -if ${ac_cv_prog_cc_g+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_save_c_werror_flag=$ac_c_werror_flag - ac_c_werror_flag=yes - ac_cv_prog_cc_g=no - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -else - CFLAGS="" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else - ac_c_werror_flag=$ac_save_c_werror_flag - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - ac_c_werror_flag=$ac_save_c_werror_flag -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 -$as_echo "$ac_cv_prog_cc_g" >&6; } -if test "$ac_test_CFLAGS" = set; then - CFLAGS=$ac_save_CFLAGS -elif test $ac_cv_prog_cc_g = yes; then - if test "$GCC" = yes; then - CFLAGS="-g -O2" - else - CFLAGS="-g" - fi -else - if test "$GCC" = yes; then - CFLAGS="-O2" - else - CFLAGS= - fi -fi - fi - fi - case `uname -s` in AIX*) @@ -13408,60 +13270,6 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu Darwin) - 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 - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the Metrowerks C compiler" >&5 -$as_echo_n "checking whether we are using the Metrowerks C compiler... " >&6; } -if ${bakefile_cv_c_compiler___MWERKS__+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - #ifndef __MWERKS__ - choke me - #endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - bakefile_cv_c_compiler___MWERKS__=yes -else - bakefile_cv_c_compiler___MWERKS__=no - -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $bakefile_cv_c_compiler___MWERKS__" >&5 -$as_echo "$bakefile_cv_c_compiler___MWERKS__" >&6; } - if test "x$bakefile_cv_c_compiler___MWERKS__" = "xyes"; then - :; MWCC=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 "$MWCC" != "yes"; then - - ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' @@ -13513,7 +13321,6 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu - fi ;; IRIX*) @@ -14540,144 +14347,6 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu fi if test "x$GCXX" != "xyes"; then - if test "xCXX" = "xC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler requires -ext o" >&5 -$as_echo_n "checking if the C compiler requires -ext o... " >&6; } -if ${bakefile_cv_c_exto+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest.$ac_ext.o -if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - for ac_file in `(ls conftest.* 2>/dev/null)`; do - case $ac_file in - conftest.$ac_ext.o) - bakefile_cv_c_exto="-ext o" - ;; - *) - ;; - esac -done -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot figure out if compiler needs -ext o: cannot compile -See \`config.log' for more details" "$LINENO" 5; } - -fi -rm -f conftest.$ac_ext.o conftest.$ac_objext conftest.$ac_ext - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $bakefile_cv_c_exto" >&5 -$as_echo "$bakefile_cv_c_exto" >&6; } -if test "x$bakefile_cv_c_exto" '!=' "x"; then - if test "c" = "c"; then - CFLAGS="$bakefile_cv_c_exto $CFLAGS" - fi - if test "c" = "cxx"; then - CXXFLAGS="$bakefile_cv_c_exto $CXXFLAGS" - fi -fi - - if test "x$bakefile_cv_c_exto" '!=' "x"; then - unset ac_cv_prog_cc_g - ac_test_CFLAGS=${CFLAGS+set} -ac_save_CFLAGS=$CFLAGS -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 -$as_echo_n "checking whether $CC accepts -g... " >&6; } -if ${ac_cv_prog_cc_g+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_save_c_werror_flag=$ac_c_werror_flag - ac_c_werror_flag=yes - ac_cv_prog_cc_g=no - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -else - CFLAGS="" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else - ac_c_werror_flag=$ac_save_c_werror_flag - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - ac_c_werror_flag=$ac_save_c_werror_flag -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 -$as_echo "$ac_cv_prog_cc_g" >&6; } -if test "$ac_test_CFLAGS" = set; then - CFLAGS=$ac_save_CFLAGS -elif test $ac_cv_prog_cc_g = yes; then - if test "$GCC" = yes; then - CFLAGS="-g -O2" - else - CFLAGS="-g" - fi -else - if test "$GCC" = yes; then - CFLAGS="-O2" - else - CFLAGS= - fi -fi - fi - fi - case `uname -s` in AIX*) @@ -14738,60 +14407,6 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu Darwin) - ac_ext=cpp -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 - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the Metrowerks C++ compiler" >&5 -$as_echo_n "checking whether we are using the Metrowerks C++ compiler... " >&6; } -if ${bakefile_cv_cxx_compiler___MWERKS__+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - #ifndef __MWERKS__ - choke me - #endif - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_compile "$LINENO"; then : - bakefile_cv_cxx_compiler___MWERKS__=yes -else - bakefile_cv_cxx_compiler___MWERKS__=no - -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $bakefile_cv_cxx_compiler___MWERKS__" >&5 -$as_echo "$bakefile_cv_cxx_compiler___MWERKS__" >&6; } - if test "x$bakefile_cv_cxx_compiler___MWERKS__" = "xyes"; then - :; MWCXX=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 "$MWCXX" != "yes"; then - - ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' @@ -14843,7 +14458,6 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu - fi ;; IRIX*) @@ -35739,13 +35353,6 @@ OBJCXXFLAGS=`echo $WXCONFIG_CXXFLAGS $C_AND_CXX_FLAGS $OBJCXXFLAGS ` WXCONFIG_CPPFLAGS=`echo $WXCONFIG_CPPFLAGS $WXCONFIG_ONLY_CPPFLAGS` -if test "x$MWCC" = "xyes"; then - - CC="$CC -cwd source -I-" - CXX="$CXX -cwd source -I-" -fi - - LIBS=`echo $LIBS` EXTRALIBS="$LDFLAGS $LDFLAGS_VERSIONING $LIBS $DMALLOC_LIBS" EXTRALIBS_XML="$EXPAT_LINK" @@ -37044,11 +36651,6 @@ $as_echo "disabled" >&6; } DEPSFLAG="-MMD" { $as_echo "$as_me:${as_lineno-$LINENO}: result: gcc" >&5 $as_echo "gcc" >&6; } - elif test "x$MWCC" = "xyes"; then - DEPSMODE=mwcc - DEPSFLAG="-MM" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: mwcc" >&5 -$as_echo "mwcc" >&6; } elif test "x$SUNCC" = "xyes"; then DEPSMODE=unixcc DEPSFLAG="-xM1" @@ -37140,34 +36742,6 @@ if test ${D}DEPSMODE = gcc ; then fi exit 0 -elif test ${D}DEPSMODE = mwcc ; then - ${D}* || exit ${D}? - # Run mwcc again with -MM and redirect into the dep file we want - # NOTE: We can't use shift here because we need ${D}* to be valid - prevarg= - for arg in ${D}* ; do - if test "${D}prevarg" = "-o"; then - objfile=${D}arg - else - case "${D}arg" in - -* ) - ;; - * ) - srcfile=${D}arg - ;; - esac - fi - prevarg="${D}arg" - done - - objfilebase=\`basename ${D}objfile\` - builddir=\`dirname ${D}objfile\` - depsdir=${D}builddir/${D}DEPSDIRBASE - mkdir -p ${D}depsdir - - ${D}* ${D}DEPSFLAG >${D}{depsdir}/${D}{objfilebase}.d - exit 0 - elif test ${D}DEPSMODE = unixcc; then ${D}* || exit ${D}? # Run compiler again with deps flag and redirect into the dep file. diff --git a/configure.in b/configure.in index 1290fd0f8e..8b9b8505fc 100644 --- a/configure.in +++ b/configure.in @@ -7611,22 +7611,6 @@ dnl only stuff to it WXCONFIG_CPPFLAGS=`echo $WXCONFIG_CPPFLAGS $WXCONFIG_ONLY_CPPFLAGS` -if test "x$MWCC" = "xyes"; then - dnl Correct MW 8.3 to be more similar to GCC. In particular we - dnl must use from system not our local copy on OS X, - dnl but must use local not system on OS 9. - dnl The following should make all -I paths usable for <> includes - dnl while first checking in real system paths. With 8.3 using - dnl -gccincludes it will actually check local paths before system - dnl even for <> which is totally wrong. - - dnl Note that because this absolutely needs to be before any -I - dnl that we have to tack it on to the end of the compiler commandline. - CC="$CC -cwd source -I-" - CXX="$CXX -cwd source -I-" -fi - - LIBS=`echo $LIBS` EXTRALIBS="$LDFLAGS $LDFLAGS_VERSIONING $LIBS $DMALLOC_LIBS" EXTRALIBS_XML="$EXPAT_LINK"