aboutsummaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorDave Korn <dave.korn@artimi.com>2010-10-07 20:50:02 +0000
committerDave Korn <dave.korn@artimi.com>2010-10-07 20:50:02 +0000
commita8eb3f0a482ef60bd7dc0acc9e3113173d5b8e79 (patch)
treecfe409eb47304cf3cd42280b8deed845cb6317a9 /configure.ac
parent00e14314cf12ad2a25566b75dd924e361715e106 (diff)
downloadgdb-a8eb3f0a482ef60bd7dc0acc9e3113173d5b8e79.zip
gdb-a8eb3f0a482ef60bd7dc0acc9e3113173d5b8e79.tar.gz
gdb-a8eb3f0a482ef60bd7dc0acc9e3113173d5b8e79.tar.bz2
* configure.ac (build_lto_plugin): New shell variable.
(--enable-lto): Turn on by default for all non-ELF platforms that have had LTO support added so far. Set build_lto_plugin appropriately for both ELF and non-ELF. (configdirs): Add lto-plugin or not based on build_lto_plugin. * configure: Regenerate.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac13
1 files changed, 10 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac
index 6af4be1..bf5fe3a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1786,9 +1786,11 @@ to specify its location.])
# Flags needed for libelf.
AC_SUBST(libelflibs)
AC_SUBST(libelfinc)
+ # ELF platforms build the lto-plugin when GOLD is in use.
+ build_lto_plugin=${ENABLE_GOLD}
fi],[if test x"$default_enable_lto" = x"yes" ; then
case $target in
- *-apple-darwin*) ;;
+ *-apple-darwin* | *-cygwin* | *-mingw*) ;;
# On other non-ELF platforms, LTO must be explicitly enabled.
*) enable_lto=no ;;
esac
@@ -1799,13 +1801,18 @@ fi],[if test x"$default_enable_lto" = x"yes" ; then
# warn during gcc/ subconfigure; unless you're bootstrapping with
# -flto it won't be needed until after installation anyway.
case $target in
- *-cygwin*|*-mingw* | *-apple-darwin*) ;;
+ *-cygwin* | *-mingw* | *-apple-darwin*) ;;
*) if test x"$enable_lto" = x"yes"; then
AC_MSG_ERROR([LTO support is not enabled for this target.])
fi
;;
esac
fi
+ # Among non-ELF, only Windows platforms support the lto-plugin so far.
+ case $target in
+ *-cygwin* | *-mingw*) build_lto_plugin=yes ;;
+ *) ;;
+ esac
default_enable_lto=no])
@@ -1884,7 +1891,7 @@ if test -d ${srcdir}/gcc; then
*,lto,*) ;;
*) enable_languages="${enable_languages},lto" ;;
esac
- if test "${ENABLE_GOLD}" = "yes" ; then
+ if test "${build_lto_plugin}" = "yes" ; then
configdirs="$configdirs lto-plugin"
extra_host_libiberty_configure_flags=--enable-shared
fi