]> git.ipfire.org Git - thirdparty/grub.git/commitdiff
* configure.ac: Restore CFLAGS to TARGET_CFLAGS before external tests.
authorVladimir Serbinenko <phcoder@gmail.com>
Sun, 10 Nov 2013 12:10:45 +0000 (13:10 +0100)
committerVladimir Serbinenko <phcoder@gmail.com>
Sun, 10 Nov 2013 12:10:45 +0000 (13:10 +0100)
Add -march=core2 when testing compile of efiemu64.

Thanks Andrey Borzenkov for spotting this.

ChangeLog
configure.ac

index 0f4df906725c9f81e04430508836cb4f054f5b5a..29d59587bfdf2844f7a27107f47a6b7697bcd828 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2013-11-09  Vladimir Serbinenko  <phcoder@gmail.com>
+
+       * configure.ac: Restore CFLAGS to TARGET_CFLAGS before external tests.
+       Add -march=core2 when testing compile of efiemu64.
+
+       Thanks Andrey Borzenkov for spotting this.
+
 2013-11-09  Vladimir Serbinenko  <phcoder@gmail.com>
 
        Add new ports: i386-xen and x86_64-xen. This allows running GRUB in
index 3232a8089f585c29d771485f15b64523c12df917..b321ae41cc9c5ab6abe1f2df2787bd4b568f6953 100644 (file)
@@ -672,7 +672,7 @@ if test x"$platform" = xefi ; then
 fi
 if test x"$efiemu_excuse" = x ; then
   AC_CACHE_CHECK([whether options required for efiemu work], grub_cv_cc_efiemu, [
-    CFLAGS="$TARGET_CFLAGS -m64 -mcmodel=large -mno-red-zone -nostdlib"
+    CFLAGS="$TARGET_CFLAGS -march=core2 -m64 -mcmodel=large -mno-red-zone -nostdlib"
     AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[]])],
                      [grub_cv_cc_efiemu=yes],
                      [grub_cv_cc_efiemu=no])
@@ -762,6 +762,8 @@ fi
 # Compiler features.
 #
 
+CFLAGS="$TARGET_CFLAGS"
+
 # Position independent executable.
 grub_CHECK_PIE
 [# Need that, because some distributions ship compilers that include
@@ -770,6 +772,8 @@ if [ x"$pie_possible" = xyes ]; then
   TARGET_CFLAGS="$TARGET_CFLAGS -fno-PIE"
 fi]
 
+CFLAGS="$TARGET_CFLAGS"
+
 # Position independent executable.
 grub_CHECK_PIC
 [# Need that, because some distributions ship compilers that include
@@ -778,6 +782,8 @@ if [ x"$pic_possible" = xyes ]; then
   TARGET_CFLAGS="$TARGET_CFLAGS -fno-PIC"
 fi]
 
+CFLAGS="$TARGET_CFLAGS"
+
 # Smashing stack protector.
 grub_CHECK_STACK_PROTECTOR
 # Need that, because some distributions ship compilers that include
@@ -785,6 +791,9 @@ grub_CHECK_STACK_PROTECTOR
 if test "x$ssp_possible" = xyes; then
   TARGET_CFLAGS="$TARGET_CFLAGS -fno-stack-protector"
 fi
+
+CFLAGS="$TARGET_CFLAGS"
+
 grub_CHECK_STACK_ARG_PROBE
 # Cygwin's GCC uses alloca() to probe the stackframe on static
 # stack allocations above some threshold.
@@ -792,6 +801,8 @@ if test x"$sap_possible" = xyes; then
   TARGET_CFLAGS="$TARGET_CFLAGS -mno-stack-arg-probe"
 fi
 
+CFLAGS="$TARGET_CFLAGS"
+
 # -mno-unaligned-access
 if test "$target_cpu" = arm; then
   grub_CHECK_NO_UNALIGNED_ACCESS