]> git.eshelyaron.com Git - emacs.git/commitdiff
Port to GCC 4.9.0 with link time optimization.
authorPaul Eggert <eggert@cs.ucla.edu>
Fri, 20 Jun 2014 06:07:47 +0000 (23:07 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Fri, 20 Jun 2014 06:07:47 +0000 (23:07 -0700)
* configure.ac (CFLAGS): With link time optimization,
use -ffat-lto-objects if supported; otherwise Emacs won't
build with GCC 4.9.0.

Fixes: debbugs:17806
ChangeLog
configure.ac

index fd87a78c7c8929bf31d78390a450d4ee21c97cb5..17d3f9401a39b8f4462bcc151d298dee842d5644 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2014-06-20  Paul Eggert  <eggert@cs.ucla.edu>
+
+       Port to GCC 4.9.0 with link time optimization (Bug#17806).
+       * configure.ac (CFLAGS): With link time optimization,
+       use -ffat-lto-objects if supported; otherwise Emacs won't
+       build with GCC 4.9.0.
+
 2014-06-14  Paul Eggert  <eggert@cs.ucla.edu>
 
        Port part of the AIX fix to Solaris (Bug#17598).
index 702b8570577ac2a3882df299de44011932840cc6..e9400047edcaaccebc0c03990d547b4f97e38072 100644 (file)
@@ -777,6 +777,12 @@ if test "${enableval}" != "no"; then
    AC_MSG_RESULT([$ac_lto_supported])
    if test "$ac_lto_supported" = "yes"; then
       CFLAGS="$CFLAGS $LTO"
+      dnl The following is needed for GCC 4.9.0.  The GCC 4.9.0 release notes
+      dnl suggest that instead of -ffat-lto-objects we should use gcc-ar and
+      dnl gcc-ranlib in place of ar and ranlib, but gcc-ar makes /usr/bin/ar
+      dnl dump core on Fedora 20, so play it safe for now.
+      gl_COMPILER_OPTION_IF([-ffat-lto-objects],
+       [CFLAGS="$CFLAGS -ffat-lto-objects"])
    fi
 fi)