From: Glenn Morris Date: Sat, 27 Apr 2013 10:17:37 +0000 (-0400) Subject: Auto-commit of generated files. X-Git-Tag: emacs-24.3.90~173^2^2~42^2~45^2~387^2~2026^2~359^2 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=8beecaeda0d28bff0c4d3c2758bb938c656728b5;p=emacs.git Auto-commit of generated files. --- diff --git a/autogen/configure b/autogen/configure index 7ddac01fb10..bd900b5afef 100755 --- a/autogen/configure +++ b/autogen/configure @@ -7271,10 +7271,10 @@ esac # Code from module xalloc-oversized: -# It's helpful to have C macros available to GDB, so prefer -g3 to -g -# if -g3 works and the user does not specify CFLAGS. -# This test must follow gl_EARLY; otherwise AC_LINK_IFELSE complains. if test "$ac_test_CFLAGS" != set; then + # It's helpful to have C macros available to GDB, so prefer -g3 to -g + # if -g3 works and the user does not specify CFLAGS. + # This test must follow gl_EARLY; otherwise AC_LINK_IFELSE complains. case $CFLAGS in '-g') emacs_g3_CFLAGS='-g3';; @@ -7312,12 +7312,49 @@ rm -f core conftest.err conftest.$ac_objext \ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_g3" >&5 $as_echo "$emacs_cv_prog_cc_g3" >&6; } - if test $emacs_cv_prog_cc_g3 = yes; then - CFLAGS=$emacs_g3_CFLAGS - else + if test $emacs_cv_prog_cc_g3 != yes; then CFLAGS=$emacs_save_CFLAGS fi fi + + case $CFLAGS in + *-O*) ;; + *) + # No optimization flag was inferred for this non-GCC compiler. + # Try -O. This is needed for xlc on AIX; see Bug#14258. + emacs_save_CFLAGS=$CFLAGS + test -z "$CFLAGS" || CFLAGS="$CFLAGS " + CFLAGS=${CFLAGS}-O + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -O" >&5 +$as_echo_n "checking whether $CC accepts -O... " >&6; } +if test "${emacs_cv_prog_cc_o+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + emacs_cv_prog_cc_o=yes +else + emacs_cv_prog_cc_o=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_o" >&5 +$as_echo "$emacs_cv_prog_cc_o" >&6; } + if test $emacs_cv_prog_cc_o != yes; then + CFLAGS=$emacs_save_CFLAGS + fi ;; + esac fi # Check whether --enable-gcc-warnings was given.