From 322562eae83f8dba0df5552527dd686574fd93d8 Mon Sep 17 00:00:00 2001 From: proski Date: Thu, 10 Apr 2008 22:26:50 +0000 Subject: [PATCH] 2008-04-10 Pavel Roskin * configure.ac: Always use "_cv_" in cache variables for compatibility with Autoconf 2.62. --- ChangeLog | 5 +++++ configure | 24 ++++++++++++------------ configure.ac | 12 ++++++------ 3 files changed, 23 insertions(+), 18 deletions(-) diff --git a/ChangeLog b/ChangeLog index 07241dd6d..1164b4084 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2008-04-10 Pavel Roskin + + * configure.ac: Always use "_cv_" in cache variables for + compatibility with Autoconf 2.62. + 2008-04-07 Robert Millan Revert grub/machine/init.h addition by Pavel (since it breaks on diff --git a/configure b/configure index d4f9276a9..2517a3c62 100644 --- a/configure +++ b/configure @@ -6561,7 +6561,7 @@ if test "x$TARGET_CFLAGS" = x; then # optimization flags. { echo "$as_me:$LINENO: checking whether optimization for size works" >&5 echo $ECHO_N "checking whether optimization for size works... $ECHO_C" >&6; } -if test "${size_flag+set}" = set; then +if test "${grub_cv_cc_Os+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else @@ -6598,20 +6598,20 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then - size_flag=yes + grub_cv_cc_Os=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - size_flag=no + grub_cv_cc_Os=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ echo "$as_me:$LINENO: result: $size_flag" >&5 -echo "${ECHO_T}$size_flag" >&6; } - if test "x$size_flag" = xyes; then +{ echo "$as_me:$LINENO: result: $grub_cv_cc_Os" >&5 +echo "${ECHO_T}$grub_cv_cc_Os" >&6; } + if test "x$grub_cv_cc_Os" = xyes; then TARGET_CFLAGS="$TARGET_CFLAGS -Os" else TARGET_CFLAGS="$TARGET_CFLAGS -O2 -fno-strength-reduce -fno-unroll-loops" @@ -6621,7 +6621,7 @@ echo "${ECHO_T}$size_flag" >&6; } if test "x$target_cpu" = xi386; then { echo "$as_me:$LINENO: checking whether -falign-loops works" >&5 echo $ECHO_N "checking whether -falign-loops works... $ECHO_C" >&6; } -if test "${falign_loop_flag+set}" = set; then +if test "${grub_cv_cc_falign_loop+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else @@ -6658,21 +6658,21 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then - falign_loop_flag=yes + grub_cv_cc_falign_loop=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - falign_loop_flag=no + grub_cv_cc_falign_loop=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ echo "$as_me:$LINENO: result: $falign_loop_flag" >&5 -echo "${ECHO_T}$falign_loop_flag" >&6; } +{ echo "$as_me:$LINENO: result: $grub_cv_cc_falign_loop" >&5 +echo "${ECHO_T}$grub_cv_cc_falign_loop" >&6; } - if test "x$falign_loop_flag" = xyes; then + if test "x$grub_cv_cc_falign_loop" = xyes; then TARGET_CFLAGS="$TARGET_CFLAGS -falign-jumps=1 -falign-loops=1 -falign-functions=1" else TARGET_CFLAGS="$TARGET_CFLAGS -malign-jumps=1 -malign-loops=1 -malign-functions=1" diff --git a/configure.ac b/configure.ac index 3a737f47e..80cb54238 100644 --- a/configure.ac +++ b/configure.ac @@ -207,11 +207,11 @@ if test "x$TARGET_CFLAGS" = x; then -Wundef -Wstrict-prototypes -g" # optimization flags. - AC_CACHE_CHECK([whether optimization for size works], size_flag, [ + AC_CACHE_CHECK([whether optimization for size works], grub_cv_cc_Os, [ CFLAGS=-Os - AC_TRY_COMPILE(, , size_flag=yes, size_flag=no) + AC_TRY_COMPILE(, , grub_cv_cc_Os=yes, grub_cv_cc_Os=no) ]) - if test "x$size_flag" = xyes; then + if test "x$grub_cv_cc_Os" = xyes; then TARGET_CFLAGS="$TARGET_CFLAGS -Os" else TARGET_CFLAGS="$TARGET_CFLAGS -O2 -fno-strength-reduce -fno-unroll-loops" @@ -219,12 +219,12 @@ if test "x$TARGET_CFLAGS" = x; then # Force no alignment to save space on i386. if test "x$target_cpu" = xi386; then - AC_CACHE_CHECK([whether -falign-loops works], [falign_loop_flag], [ + AC_CACHE_CHECK([whether -falign-loops works], [grub_cv_cc_falign_loop], [ CFLAGS="-falign-loops=1" - AC_TRY_COMPILE(, , [falign_loop_flag=yes], [falign_loop_flag=no]) + AC_TRY_COMPILE(, , [grub_cv_cc_falign_loop=yes], [grub_cv_cc_falign_loop=no]) ]) - if test "x$falign_loop_flag" = xyes; then + if test "x$grub_cv_cc_falign_loop" = xyes; then TARGET_CFLAGS="$TARGET_CFLAGS -falign-jumps=1 -falign-loops=1 -falign-functions=1" else TARGET_CFLAGS="$TARGET_CFLAGS -malign-jumps=1 -malign-loops=1 -malign-functions=1"