summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDodji Seketeli <dodji@seketeli.org>2013-05-10 09:31:16 +0200
committerDodji Seketeli <dodji@seketeli.org>2013-05-24 22:41:05 +0200
commit761523d83e0fe510b8a3ad3146d407270915ea0a (patch)
tree9d60fae6ad30d0e1de4b31141f7894ac004cbbbb
parentbe4b653b22b4c8207db8ee9a59f55618e1d02311 (diff)
downloadgcc-761523d83e0fe510b8a3ad3146d407270915ea0a.tar.gz
Wire libabigail to the GCC build system
/ * configure.ac: Allow the use of libabigail either as an external dependency or as a library built from within the source tree of GCC. * Makefile.def: Add libabigail as new host_module. * Makefile.tpl: Define ABIGAILLIBS, ABIGAILINC HOST_ABIGAILLIBS and HOST_ABIGAILLIBS, and pass ABIGAILINC, ABIGAILLIBS to gcc/configure. * config/abigail.m4: New m4 macro library file, copied verbatim from libabigail. This is used to detect the library, its version etc. * Makefile.in: Re-generate. * configure: Likewise. gcc/ * configure.ac: Recognize ABIGAILLIBS and ABIGAILINC as precious variables. * Makefile.in: Add abigail library to BACKENDLIBS, and abigail headers path to INCLUDES. * configure: Re-generate. * config.in: Likewise. gcc/cp/ * cp/abi-instr.c: New file. * gcc/cp/Make-lang.in: Add abi-instr.c to the build system.
-rw-r--r--Makefile.def3
-rw-r--r--Makefile.in964
-rw-r--r--Makefile.tpl6
-rw-r--r--config/abigail.m4177
-rwxr-xr-xconfigure869
-rw-r--r--configure.ac28
-rw-r--r--gcc/Makefile.in8
-rw-r--r--gcc/config.in6
-rwxr-xr-xgcc/configure20
-rw-r--r--gcc/configure.ac6
-rw-r--r--gcc/cp/Make-lang.in4
-rw-r--r--gcc/cp/abi-instr.c25
12 files changed, 2107 insertions, 9 deletions
diff --git a/Makefile.def b/Makefile.def
index 90d9653d530..74034d29fc6 100644
--- a/Makefile.def
+++ b/Makefile.def
@@ -70,6 +70,9 @@ host_modules= { module= cloog; lib_path=.libs; bootstrap=true;
extra_exports='CPPFLAGS="$(HOST_GMPINC) $(HOST_ISLINC) $$CPPFLAGS"; export CPPFLAGS; LDFLAGS="-L$$r/$(HOST_SUBDIR)/gmp/.libs -L$$r/$(HOST_SUBDIR)/isl/.libs $$LDFLAGS"; export LDFLAGS; ';
extra_make_flags='CPPFLAGS="$$CPPFLAGS" LDFLAGS="$$LDFLAGS" V=1';
no_install= true; };
+host_modules= { module= libabigail; lib_path=.libs; bootstrap=true;
+ extra_make_flags='V=1';
+ no_install= true; };
host_modules= { module= libelf; lib_path=.libs; bootstrap=true;
extra_configure_flags='--disable-shared';
no_install= true; };
diff --git a/Makefile.in b/Makefile.in
index bfbaf03417a..dfbb60d499f 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -222,6 +222,8 @@ HOST_EXPORTS = \
ISLINC="$(HOST_ISLINC)"; export ISLINC; \
CLOOGLIBS="$(HOST_CLOOGLIBS)"; export CLOOGLIBS; \
CLOOGINC="$(HOST_CLOOGINC)"; export CLOOGINC; \
+ ABIGAILLIBS="$(HOST_ABIGAILLIBS)"; export ABIGAILLIBS; \
+ ABIGAILINC="$(HOST_ABIGAILINC)"; export ABIGAILINC; \
LIBELFLIBS="$(HOST_LIBELFLIBS)" ; export LIBELFLIBS; \
LIBELFINC="$(HOST_LIBELFINC)" ; export LIBELFINC; \
@if gcc-bootstrap
@@ -316,6 +318,10 @@ HOST_ISLINC = @islinc@
HOST_CLOOGLIBS = @clooglibs@
HOST_CLOOGINC = @clooginc@
+# Where to find libabigail
+HOST_ABIGAILLIBS = @abigaillibs@
+HOST_ABIGAILINC = @abigailinc@
+
# Where to find libelf
HOST_LIBELFLIBS = @libelflibs@
HOST_LIBELFINC = @libelfinc@
@@ -609,7 +615,7 @@ TARGET_LIB_PATH_libatomic = $$r/$(TARGET_SUBDIR)/libatomic/.libs:
# This is the list of directories that may be needed in RPATH_ENVVAR
# so that programs built for the host machine work.
-HOST_LIB_PATH = $(HOST_LIB_PATH_gmp)$(HOST_LIB_PATH_mpfr)$(HOST_LIB_PATH_mpc)$(HOST_LIB_PATH_isl)$(HOST_LIB_PATH_cloog)$(HOST_LIB_PATH_libelf)
+HOST_LIB_PATH = $(HOST_LIB_PATH_gmp)$(HOST_LIB_PATH_mpfr)$(HOST_LIB_PATH_mpc)$(HOST_LIB_PATH_isl)$(HOST_LIB_PATH_cloog)$(HOST_LIB_PATH_libabigail)$(HOST_LIB_PATH_libelf)
# Define HOST_LIB_PATH_gcc here, for the sake of TARGET_LIB_PATH, ouch
@if gcc
@@ -642,6 +648,11 @@ HOST_LIB_PATH_cloog = \
$$r/$(HOST_SUBDIR)/cloog/.libs:$$r/$(HOST_SUBDIR)/prev-cloog/.libs:
@endif cloog
+@if libabigail
+HOST_LIB_PATH_libabigail = \
+ $$r/$(HOST_SUBDIR)/libabigail/.libs:$$r/$(HOST_SUBDIR)/prev-libabigail/.libs:
+@endif libabigail
+
@if libelf
HOST_LIB_PATH_libelf = \
$$r/$(HOST_SUBDIR)/libelf/.libs:$$r/$(HOST_SUBDIR)/prev-libelf/.libs:
@@ -893,6 +904,7 @@ configure-host: \
maybe-configure-mpc \
maybe-configure-isl \
maybe-configure-cloog \
+ maybe-configure-libabigail \
maybe-configure-libelf \
maybe-configure-gold \
maybe-configure-gprof \
@@ -1019,6 +1031,9 @@ all-host: maybe-all-isl
@if cloog-no-bootstrap
all-host: maybe-all-cloog
@endif cloog-no-bootstrap
+@if libabigail-no-bootstrap
+all-host: maybe-all-libabigail
+@endif libabigail-no-bootstrap
@if libelf-no-bootstrap
all-host: maybe-all-libelf
@endif libelf-no-bootstrap
@@ -1134,6 +1149,7 @@ info-host: maybe-info-mpfr
info-host: maybe-info-mpc
info-host: maybe-info-isl
info-host: maybe-info-cloog
+info-host: maybe-info-libabigail
info-host: maybe-info-libelf
info-host: maybe-info-gold
info-host: maybe-info-gprof
@@ -1216,6 +1232,7 @@ dvi-host: maybe-dvi-mpfr
dvi-host: maybe-dvi-mpc
dvi-host: maybe-dvi-isl
dvi-host: maybe-dvi-cloog
+dvi-host: maybe-dvi-libabigail
dvi-host: maybe-dvi-libelf
dvi-host: maybe-dvi-gold
dvi-host: maybe-dvi-gprof
@@ -1298,6 +1315,7 @@ pdf-host: maybe-pdf-mpfr
pdf-host: maybe-pdf-mpc
pdf-host: maybe-pdf-isl
pdf-host: maybe-pdf-cloog
+pdf-host: maybe-pdf-libabigail
pdf-host: maybe-pdf-libelf
pdf-host: maybe-pdf-gold
pdf-host: maybe-pdf-gprof
@@ -1380,6 +1398,7 @@ html-host: maybe-html-mpfr
html-host: maybe-html-mpc
html-host: maybe-html-isl
html-host: maybe-html-cloog
+html-host: maybe-html-libabigail
html-host: maybe-html-libelf
html-host: maybe-html-gold
html-host: maybe-html-gprof
@@ -1462,6 +1481,7 @@ TAGS-host: maybe-TAGS-mpfr
TAGS-host: maybe-TAGS-mpc
TAGS-host: maybe-TAGS-isl
TAGS-host: maybe-TAGS-cloog
+TAGS-host: maybe-TAGS-libabigail
TAGS-host: maybe-TAGS-libelf
TAGS-host: maybe-TAGS-gold
TAGS-host: maybe-TAGS-gprof
@@ -1544,6 +1564,7 @@ install-info-host: maybe-install-info-mpfr
install-info-host: maybe-install-info-mpc
install-info-host: maybe-install-info-isl
install-info-host: maybe-install-info-cloog
+install-info-host: maybe-install-info-libabigail
install-info-host: maybe-install-info-libelf
install-info-host: maybe-install-info-gold
install-info-host: maybe-install-info-gprof
@@ -1626,6 +1647,7 @@ install-pdf-host: maybe-install-pdf-mpfr
install-pdf-host: maybe-install-pdf-mpc
install-pdf-host: maybe-install-pdf-isl
install-pdf-host: maybe-install-pdf-cloog
+install-pdf-host: maybe-install-pdf-libabigail
install-pdf-host: maybe-install-pdf-libelf
install-pdf-host: maybe-install-pdf-gold
install-pdf-host: maybe-install-pdf-gprof
@@ -1708,6 +1730,7 @@ install-html-host: maybe-install-html-mpfr
install-html-host: maybe-install-html-mpc
install-html-host: maybe-install-html-isl
install-html-host: maybe-install-html-cloog
+install-html-host: maybe-install-html-libabigail
install-html-host: maybe-install-html-libelf
install-html-host: maybe-install-html-gold
install-html-host: maybe-install-html-gprof
@@ -1790,6 +1813,7 @@ installcheck-host: maybe-installcheck-mpfr
installcheck-host: maybe-installcheck-mpc
installcheck-host: maybe-installcheck-isl
installcheck-host: maybe-installcheck-cloog
+installcheck-host: maybe-installcheck-libabigail
installcheck-host: maybe-installcheck-libelf
installcheck-host: maybe-installcheck-gold
installcheck-host: maybe-installcheck-gprof
@@ -1872,6 +1896,7 @@ mostlyclean-host: maybe-mostlyclean-mpfr
mostlyclean-host: maybe-mostlyclean-mpc
mostlyclean-host: maybe-mostlyclean-isl
mostlyclean-host: maybe-mostlyclean-cloog
+mostlyclean-host: maybe-mostlyclean-libabigail
mostlyclean-host: maybe-mostlyclean-libelf
mostlyclean-host: maybe-mostlyclean-gold
mostlyclean-host: maybe-mostlyclean-gprof
@@ -1954,6 +1979,7 @@ clean-host: maybe-clean-mpfr
clean-host: maybe-clean-mpc
clean-host: maybe-clean-isl
clean-host: maybe-clean-cloog
+clean-host: maybe-clean-libabigail
clean-host: maybe-clean-libelf
clean-host: maybe-clean-gold
clean-host: maybe-clean-gprof
@@ -2036,6 +2062,7 @@ distclean-host: maybe-distclean-mpfr
distclean-host: maybe-distclean-mpc
distclean-host: maybe-distclean-isl
distclean-host: maybe-distclean-cloog
+distclean-host: maybe-distclean-libabigail
distclean-host: maybe-distclean-libelf
distclean-host: maybe-distclean-gold
distclean-host: maybe-distclean-gprof
@@ -2118,6 +2145,7 @@ maintainer-clean-host: maybe-maintainer-clean-mpfr
maintainer-clean-host: maybe-maintainer-clean-mpc
maintainer-clean-host: maybe-maintainer-clean-isl
maintainer-clean-host: maybe-maintainer-clean-cloog
+maintainer-clean-host: maybe-maintainer-clean-libabigail
maintainer-clean-host: maybe-maintainer-clean-libelf
maintainer-clean-host: maybe-maintainer-clean-gold
maintainer-clean-host: maybe-maintainer-clean-gprof
@@ -2255,6 +2283,7 @@ check-host: \
maybe-check-mpc \
maybe-check-isl \
maybe-check-cloog \
+ maybe-check-libabigail \
maybe-check-libelf \
maybe-check-gold \
maybe-check-gprof \
@@ -2363,6 +2392,7 @@ install-host-nogcc: \
maybe-install-mpc \
maybe-install-isl \
maybe-install-cloog \
+ maybe-install-libabigail \
maybe-install-libelf \
maybe-install-gold \
maybe-install-gprof \
@@ -2410,6 +2440,7 @@ install-host: \
maybe-install-mpc \
maybe-install-isl \
maybe-install-cloog \
+ maybe-install-libabigail \
maybe-install-libelf \
maybe-install-gold \
maybe-install-gprof \
@@ -2512,6 +2543,7 @@ install-strip-host: \
maybe-install-strip-mpc \
maybe-install-strip-isl \
maybe-install-strip-cloog \
+ maybe-install-strip-libabigail \
maybe-install-strip-libelf \
maybe-install-strip-gold \
maybe-install-strip-gprof \
@@ -14714,6 +14746,866 @@ maintainer-clean-cloog:
+.PHONY: configure-libabigail maybe-configure-libabigail
+maybe-configure-libabigail:
+@if gcc-bootstrap
+configure-libabigail: stage_current
+@endif gcc-bootstrap
+@if libabigail
+maybe-configure-libabigail: configure-libabigail
+configure-libabigail:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ test ! -f $(HOST_SUBDIR)/libabigail/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(HOST_SUBDIR)/libabigail ; \
+ $(HOST_EXPORTS) \
+ echo Configuring in $(HOST_SUBDIR)/libabigail; \
+ cd "$(HOST_SUBDIR)/libabigail" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) topdir=$(srcdir) ;; \
+ *) topdir=`echo $(HOST_SUBDIR)/libabigail/ | \
+ sed -e 's,\./,,g' -e 's,[^/]*/,../,g' `$(srcdir) ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/libabigail"; \
+ libsrcdir="$$s/libabigail"; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) --build=${build_alias} --host=${host_alias} \
+ --target=${target_alias} $${srcdiroption} \
+ || exit 1
+@endif libabigail
+
+
+
+.PHONY: configure-stage1-libabigail maybe-configure-stage1-libabigail
+maybe-configure-stage1-libabigail:
+@if libabigail-bootstrap
+maybe-configure-stage1-libabigail: configure-stage1-libabigail
+configure-stage1-libabigail:
+ @[ $(current_stage) = stage1 ] || $(MAKE) stage1-start
+ @$(SHELL) $(srcdir)/mkinstalldirs $(HOST_SUBDIR)/libabigail
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ TFLAGS="$(STAGE1_TFLAGS)"; \
+ test ! -f $(HOST_SUBDIR)/libabigail/Makefile || exit 0; \
+ $(HOST_EXPORTS) \
+ CFLAGS="$(STAGE1_CFLAGS)"; export CFLAGS; \
+ CXXFLAGS="$(STAGE1_CXXFLAGS)"; export CXXFLAGS; \
+ LIBCFLAGS="$(LIBCFLAGS)"; export LIBCFLAGS; \
+ echo Configuring stage 1 in $(HOST_SUBDIR)/libabigail ; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(HOST_SUBDIR)/libabigail ; \
+ cd $(HOST_SUBDIR)/libabigail || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) topdir=$(srcdir) ;; \
+ *) topdir=`echo $(HOST_SUBDIR)/libabigail/ | \
+ sed -e 's,\./,,g' -e 's,[^/]*/,../,g' `$(srcdir) ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/libabigail"; \
+ libsrcdir="$$s/libabigail"; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) --build=${build_alias} --host=${host_alias} \
+ --target=${target_alias} $${srcdiroption} \
+ $(STAGE1_CONFIGURE_FLAGS)
+@endif libabigail-bootstrap
+
+.PHONY: configure-stage2-libabigail maybe-configure-stage2-libabigail
+maybe-configure-stage2-libabigail:
+@if libabigail-bootstrap
+maybe-configure-stage2-libabigail: configure-stage2-libabigail
+configure-stage2-libabigail:
+ @[ $(current_stage) = stage2 ] || $(MAKE) stage2-start
+ @$(SHELL) $(srcdir)/mkinstalldirs $(HOST_SUBDIR)/libabigail
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ TFLAGS="$(STAGE2_TFLAGS)"; \
+ test ! -f $(HOST_SUBDIR)/libabigail/Makefile || exit 0; \
+ $(HOST_EXPORTS) \
+ $(POSTSTAGE1_HOST_EXPORTS) \
+ CFLAGS="$(STAGE2_CFLAGS)"; export CFLAGS; \
+ CXXFLAGS="$(STAGE2_CXXFLAGS)"; export CXXFLAGS; \
+ LIBCFLAGS="$(STAGE2_CFLAGS)"; export LIBCFLAGS; \
+ echo Configuring stage 2 in $(HOST_SUBDIR)/libabigail ; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(HOST_SUBDIR)/libabigail ; \
+ cd $(HOST_SUBDIR)/libabigail || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) topdir=$(srcdir) ;; \
+ *) topdir=`echo $(HOST_SUBDIR)/libabigail/ | \
+ sed -e 's,\./,,g' -e 's,[^/]*/,../,g' `$(srcdir) ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/libabigail"; \
+ libsrcdir="$$s/libabigail"; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) --build=${build_alias} --host=${host_alias} \
+ --target=${target_alias} $${srcdiroption} \
+ --with-build-libsubdir=$(HOST_SUBDIR) \
+ $(STAGE2_CONFIGURE_FLAGS)
+@endif libabigail-bootstrap
+
+.PHONY: configure-stage3-libabigail maybe-configure-stage3-libabigail
+maybe-configure-stage3-libabigail:
+@if libabigail-bootstrap
+maybe-configure-stage3-libabigail: configure-stage3-libabigail
+configure-stage3-libabigail:
+ @[ $(current_stage) = stage3 ] || $(MAKE) stage3-start
+ @$(SHELL) $(srcdir)/mkinstalldirs $(HOST_SUBDIR)/libabigail
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ TFLAGS="$(STAGE3_TFLAGS)"; \
+ test ! -f $(HOST_SUBDIR)/libabigail/Makefile || exit 0; \
+ $(HOST_EXPORTS) \
+ $(POSTSTAGE1_HOST_EXPORTS) \
+ CFLAGS="$(STAGE3_CFLAGS)"; export CFLAGS; \
+ CXXFLAGS="$(STAGE3_CXXFLAGS)"; export CXXFLAGS; \
+ LIBCFLAGS="$(STAGE3_CFLAGS)"; export LIBCFLAGS; \
+ echo Configuring stage 3 in $(HOST_SUBDIR)/libabigail ; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(HOST_SUBDIR)/libabigail ; \
+ cd $(HOST_SUBDIR)/libabigail || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) topdir=$(srcdir) ;; \
+ *) topdir=`echo $(HOST_SUBDIR)/libabigail/ | \
+ sed -e 's,\./,,g' -e 's,[^/]*/,../,g' `$(srcdir) ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/libabigail"; \
+ libsrcdir="$$s/libabigail"; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) --build=${build_alias} --host=${host_alias} \
+ --target=${target_alias} $${srcdiroption} \
+ --with-build-libsubdir=$(HOST_SUBDIR) \
+ $(STAGE3_CONFIGURE_FLAGS)
+@endif libabigail-bootstrap
+
+.PHONY: configure-stage4-libabigail maybe-configure-stage4-libabigail
+maybe-configure-stage4-libabigail:
+@if libabigail-bootstrap
+maybe-configure-stage4-libabigail: configure-stage4-libabigail
+configure-stage4-libabigail:
+ @[ $(current_stage) = stage4 ] || $(MAKE) stage4-start
+ @$(SHELL) $(srcdir)/mkinstalldirs $(HOST_SUBDIR)/libabigail
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ TFLAGS="$(STAGE4_TFLAGS)"; \
+ test ! -f $(HOST_SUBDIR)/libabigail/Makefile || exit 0; \
+ $(HOST_EXPORTS) \
+ $(POSTSTAGE1_HOST_EXPORTS) \
+ CFLAGS="$(STAGE4_CFLAGS)"; export CFLAGS; \
+ CXXFLAGS="$(STAGE4_CXXFLAGS)"; export CXXFLAGS; \
+ LIBCFLAGS="$(STAGE4_CFLAGS)"; export LIBCFLAGS; \
+ echo Configuring stage 4 in $(HOST_SUBDIR)/libabigail ; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(HOST_SUBDIR)/libabigail ; \
+ cd $(HOST_SUBDIR)/libabigail || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) topdir=$(srcdir) ;; \
+ *) topdir=`echo $(HOST_SUBDIR)/libabigail/ | \
+ sed -e 's,\./,,g' -e 's,[^/]*/,../,g' `$(srcdir) ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/libabigail"; \
+ libsrcdir="$$s/libabigail"; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) --build=${build_alias} --host=${host_alias} \
+ --target=${target_alias} $${srcdiroption} \
+ --with-build-libsubdir=$(HOST_SUBDIR) \
+ $(STAGE4_CONFIGURE_FLAGS)
+@endif libabigail-bootstrap
+
+.PHONY: configure-stageprofile-libabigail maybe-configure-stageprofile-libabigail
+maybe-configure-stageprofile-libabigail:
+@if libabigail-bootstrap
+maybe-configure-stageprofile-libabigail: configure-stageprofile-libabigail
+configure-stageprofile-libabigail:
+ @[ $(current_stage) = stageprofile ] || $(MAKE) stageprofile-start
+ @$(SHELL) $(srcdir)/mkinstalldirs $(HOST_SUBDIR)/libabigail
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ TFLAGS="$(STAGEprofile_TFLAGS)"; \
+ test ! -f $(HOST_SUBDIR)/libabigail/Makefile || exit 0; \
+ $(HOST_EXPORTS) \
+ $(POSTSTAGE1_HOST_EXPORTS) \
+ CFLAGS="$(STAGEprofile_CFLAGS)"; export CFLAGS; \
+ CXXFLAGS="$(STAGEprofile_CXXFLAGS)"; export CXXFLAGS; \
+ LIBCFLAGS="$(STAGEprofile_CFLAGS)"; export LIBCFLAGS; \
+ echo Configuring stage profile in $(HOST_SUBDIR)/libabigail ; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(HOST_SUBDIR)/libabigail ; \
+ cd $(HOST_SUBDIR)/libabigail || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) topdir=$(srcdir) ;; \
+ *) topdir=`echo $(HOST_SUBDIR)/libabigail/ | \
+ sed -e 's,\./,,g' -e 's,[^/]*/,../,g' `$(srcdir) ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/libabigail"; \
+ libsrcdir="$$s/libabigail"; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) --build=${build_alias} --host=${host_alias} \
+ --target=${target_alias} $${srcdiroption} \
+ --with-build-libsubdir=$(HOST_SUBDIR) \
+ $(STAGEprofile_CONFIGURE_FLAGS)
+@endif libabigail-bootstrap
+
+.PHONY: configure-stagefeedback-libabigail maybe-configure-stagefeedback-libabigail
+maybe-configure-stagefeedback-libabigail:
+@if libabigail-bootstrap
+maybe-configure-stagefeedback-libabigail: configure-stagefeedback-libabigail
+configure-stagefeedback-libabigail:
+ @[ $(current_stage) = stagefeedback ] || $(MAKE) stagefeedback-start
+ @$(SHELL) $(srcdir)/mkinstalldirs $(HOST_SUBDIR)/libabigail
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ TFLAGS="$(STAGEfeedback_TFLAGS)"; \
+ test ! -f $(HOST_SUBDIR)/libabigail/Makefile || exit 0; \
+ $(HOST_EXPORTS) \
+ $(POSTSTAGE1_HOST_EXPORTS) \
+ CFLAGS="$(STAGEfeedback_CFLAGS)"; export CFLAGS; \
+ CXXFLAGS="$(STAGEfeedback_CXXFLAGS)"; export CXXFLAGS; \
+ LIBCFLAGS="$(STAGEfeedback_CFLAGS)"; export LIBCFLAGS; \
+ echo Configuring stage feedback in $(HOST_SUBDIR)/libabigail ; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(HOST_SUBDIR)/libabigail ; \
+ cd $(HOST_SUBDIR)/libabigail || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) topdir=$(srcdir) ;; \
+ *) topdir=`echo $(HOST_SUBDIR)/libabigail/ | \
+ sed -e 's,\./,,g' -e 's,[^/]*/,../,g' `$(srcdir) ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/libabigail"; \
+ libsrcdir="$$s/libabigail"; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) --build=${build_alias} --host=${host_alias} \
+ --target=${target_alias} $${srcdiroption} \
+ --with-build-libsubdir=$(HOST_SUBDIR) \
+ $(STAGEfeedback_CONFIGURE_FLAGS)
+@endif libabigail-bootstrap
+
+
+
+
+
+.PHONY: all-libabigail maybe-all-libabigail
+maybe-all-libabigail:
+@if gcc-bootstrap
+all-libabigail: stage_current
+@endif gcc-bootstrap
+@if libabigail
+TARGET-libabigail=all
+maybe-all-libabigail: all-libabigail
+all-libabigail: configure-libabigail
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(HOST_EXPORTS) \
+ (cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) $(EXTRA_HOST_FLAGS) $(STAGE1_FLAGS_TO_PASS) V=1 \
+ $(TARGET-libabigail))
+@endif libabigail
+
+
+
+.PHONY: all-stage1-libabigail maybe-all-stage1-libabigail
+.PHONY: clean-stage1-libabigail maybe-clean-stage1-libabigail
+maybe-all-stage1-libabigail:
+maybe-clean-stage1-libabigail:
+@if libabigail-bootstrap
+maybe-all-stage1-libabigail: all-stage1-libabigail
+all-stage1: all-stage1-libabigail
+TARGET-stage1-libabigail = $(TARGET-libabigail)
+all-stage1-libabigail: configure-stage1-libabigail
+ @[ $(current_stage) = stage1 ] || $(MAKE) stage1-start
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ TFLAGS="$(STAGE1_TFLAGS)"; \
+ $(HOST_EXPORTS) \
+ cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) \
+ CFLAGS="$(STAGE1_CFLAGS)" \
+ CXXFLAGS="$(STAGE1_CXXFLAGS)" \
+ LIBCFLAGS="$(LIBCFLAGS)" \
+ CFLAGS_FOR_TARGET="$(CFLAGS_FOR_TARGET)" \
+ CXXFLAGS_FOR_TARGET="$(CXXFLAGS_FOR_TARGET)" \
+ LIBCFLAGS_FOR_TARGET="$(LIBCFLAGS_FOR_TARGET)" \
+ $(EXTRA_HOST_FLAGS) \
+ $(STAGE1_FLAGS_TO_PASS) V=1 \
+ TFLAGS="$(STAGE1_TFLAGS)" \
+ $(TARGET-stage1-libabigail)
+
+maybe-clean-stage1-libabigail: clean-stage1-libabigail
+clean-stage1: clean-stage1-libabigail
+clean-stage1-libabigail:
+ @if [ $(current_stage) = stage1 ]; then \
+ [ -f $(HOST_SUBDIR)/libabigail/Makefile ] || exit 0; \
+ else \
+ [ -f $(HOST_SUBDIR)/stage1-libabigail/Makefile ] || exit 0; \
+ $(MAKE) stage1-start; \
+ fi; \
+ cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(EXTRA_HOST_FLAGS) \
+ $(STAGE1_FLAGS_TO_PASS) V=1 clean
+@endif libabigail-bootstrap
+
+
+.PHONY: all-stage2-libabigail maybe-all-stage2-libabigail
+.PHONY: clean-stage2-libabigail maybe-clean-stage2-libabigail
+maybe-all-stage2-libabigail:
+maybe-clean-stage2-libabigail:
+@if libabigail-bootstrap
+maybe-all-stage2-libabigail: all-stage2-libabigail
+all-stage2: all-stage2-libabigail
+TARGET-stage2-libabigail = $(TARGET-libabigail)
+all-stage2-libabigail: configure-stage2-libabigail
+ @[ $(current_stage) = stage2 ] || $(MAKE) stage2-start
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ TFLAGS="$(STAGE2_TFLAGS)"; \
+ $(HOST_EXPORTS) \
+ $(POSTSTAGE1_HOST_EXPORTS) \
+ cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) \
+ CFLAGS="$(STAGE2_CFLAGS)" \
+ CXXFLAGS="$(STAGE2_CXXFLAGS)" \
+ LIBCFLAGS="$(STAGE2_CFLAGS)" \
+ CFLAGS_FOR_TARGET="$(CFLAGS_FOR_TARGET)" \
+ CXXFLAGS_FOR_TARGET="$(CXXFLAGS_FOR_TARGET)" \
+ LIBCFLAGS_FOR_TARGET="$(LIBCFLAGS_FOR_TARGET)" \
+ $(EXTRA_HOST_FLAGS) $(POSTSTAGE1_FLAGS_TO_PASS) V=1 \
+ TFLAGS="$(STAGE2_TFLAGS)" \
+ $(TARGET-stage2-libabigail)
+
+maybe-clean-stage2-libabigail: clean-stage2-libabigail
+clean-stage2: clean-stage2-libabigail
+clean-stage2-libabigail:
+ @if [ $(current_stage) = stage2 ]; then \
+ [ -f $(HOST_SUBDIR)/libabigail/Makefile ] || exit 0; \
+ else \
+ [ -f $(HOST_SUBDIR)/stage2-libabigail/Makefile ] || exit 0; \
+ $(MAKE) stage2-start; \
+ fi; \
+ cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(EXTRA_HOST_FLAGS) $(POSTSTAGE1_FLAGS_TO_PASS) V=1 clean
+@endif libabigail-bootstrap
+
+
+.PHONY: all-stage3-libabigail maybe-all-stage3-libabigail
+.PHONY: clean-stage3-libabigail maybe-clean-stage3-libabigail
+maybe-all-stage3-libabigail:
+maybe-clean-stage3-libabigail:
+@if libabigail-bootstrap
+maybe-all-stage3-libabigail: all-stage3-libabigail
+all-stage3: all-stage3-libabigail
+TARGET-stage3-libabigail = $(TARGET-libabigail)
+all-stage3-libabigail: configure-stage3-libabigail
+ @[ $(current_stage) = stage3 ] || $(MAKE) stage3-start
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ TFLAGS="$(STAGE3_TFLAGS)"; \
+ $(HOST_EXPORTS) \
+ $(POSTSTAGE1_HOST_EXPORTS) \
+ cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) \
+ CFLAGS="$(STAGE3_CFLAGS)" \
+ CXXFLAGS="$(STAGE3_CXXFLAGS)" \
+ LIBCFLAGS="$(STAGE3_CFLAGS)" \
+ CFLAGS_FOR_TARGET="$(CFLAGS_FOR_TARGET)" \
+ CXXFLAGS_FOR_TARGET="$(CXXFLAGS_FOR_TARGET)" \
+ LIBCFLAGS_FOR_TARGET="$(LIBCFLAGS_FOR_TARGET)" \
+ $(EXTRA_HOST_FLAGS) $(POSTSTAGE1_FLAGS_TO_PASS) V=1 \
+ TFLAGS="$(STAGE3_TFLAGS)" \
+ $(TARGET-stage3-libabigail)
+
+maybe-clean-stage3-libabigail: clean-stage3-libabigail
+clean-stage3: clean-stage3-libabigail
+clean-stage3-libabigail:
+ @if [ $(current_stage) = stage3 ]; then \
+ [ -f $(HOST_SUBDIR)/libabigail/Makefile ] || exit 0; \
+ else \
+ [ -f $(HOST_SUBDIR)/stage3-libabigail/Makefile ] || exit 0; \
+ $(MAKE) stage3-start; \
+ fi; \
+ cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(EXTRA_HOST_FLAGS) $(POSTSTAGE1_FLAGS_TO_PASS) V=1 clean
+@endif libabigail-bootstrap
+
+
+.PHONY: all-stage4-libabigail maybe-all-stage4-libabigail
+.PHONY: clean-stage4-libabigail maybe-clean-stage4-libabigail
+maybe-all-stage4-libabigail:
+maybe-clean-stage4-libabigail:
+@if libabigail-bootstrap
+maybe-all-stage4-libabigail: all-stage4-libabigail
+all-stage4: all-stage4-libabigail
+TARGET-stage4-libabigail = $(TARGET-libabigail)
+all-stage4-libabigail: configure-stage4-libabigail
+ @[ $(current_stage) = stage4 ] || $(MAKE) stage4-start
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ TFLAGS="$(STAGE4_TFLAGS)"; \
+ $(HOST_EXPORTS) \
+ $(POSTSTAGE1_HOST_EXPORTS) \
+ cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) \
+ CFLAGS="$(STAGE4_CFLAGS)" \
+ CXXFLAGS="$(STAGE4_CXXFLAGS)" \
+ LIBCFLAGS="$(STAGE4_CFLAGS)" \
+ CFLAGS_FOR_TARGET="$(CFLAGS_FOR_TARGET)" \
+ CXXFLAGS_FOR_TARGET="$(CXXFLAGS_FOR_TARGET)" \
+ LIBCFLAGS_FOR_TARGET="$(LIBCFLAGS_FOR_TARGET)" \
+ $(EXTRA_HOST_FLAGS) $(POSTSTAGE1_FLAGS_TO_PASS) V=1 \
+ TFLAGS="$(STAGE4_TFLAGS)" \
+ $(TARGET-stage4-libabigail)
+
+maybe-clean-stage4-libabigail: clean-stage4-libabigail
+clean-stage4: clean-stage4-libabigail
+clean-stage4-libabigail:
+ @if [ $(current_stage) = stage4 ]; then \
+ [ -f $(HOST_SUBDIR)/libabigail/Makefile ] || exit 0; \
+ else \
+ [ -f $(HOST_SUBDIR)/stage4-libabigail/Makefile ] || exit 0; \
+ $(MAKE) stage4-start; \
+ fi; \
+ cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(EXTRA_HOST_FLAGS) $(POSTSTAGE1_FLAGS_TO_PASS) V=1 clean
+@endif libabigail-bootstrap
+
+
+.PHONY: all-stageprofile-libabigail maybe-all-stageprofile-libabigail
+.PHONY: clean-stageprofile-libabigail maybe-clean-stageprofile-libabigail
+maybe-all-stageprofile-libabigail:
+maybe-clean-stageprofile-libabigail:
+@if libabigail-bootstrap
+maybe-all-stageprofile-libabigail: all-stageprofile-libabigail
+all-stageprofile: all-stageprofile-libabigail
+TARGET-stageprofile-libabigail = $(TARGET-libabigail)
+all-stageprofile-libabigail: configure-stageprofile-libabigail
+ @[ $(current_stage) = stageprofile ] || $(MAKE) stageprofile-start
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ TFLAGS="$(STAGEprofile_TFLAGS)"; \
+ $(HOST_EXPORTS) \
+ $(POSTSTAGE1_HOST_EXPORTS) \
+ cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) \
+ CFLAGS="$(STAGEprofile_CFLAGS)" \
+ CXXFLAGS="$(STAGEprofile_CXXFLAGS)" \
+ LIBCFLAGS="$(STAGEprofile_CFLAGS)" \
+ CFLAGS_FOR_TARGET="$(CFLAGS_FOR_TARGET)" \
+ CXXFLAGS_FOR_TARGET="$(CXXFLAGS_FOR_TARGET)" \
+ LIBCFLAGS_FOR_TARGET="$(LIBCFLAGS_FOR_TARGET)" \
+ $(EXTRA_HOST_FLAGS) $(POSTSTAGE1_FLAGS_TO_PASS) V=1 \
+ TFLAGS="$(STAGEprofile_TFLAGS)" \
+ $(TARGET-stageprofile-libabigail)
+
+maybe-clean-stageprofile-libabigail: clean-stageprofile-libabigail
+clean-stageprofile: clean-stageprofile-libabigail
+clean-stageprofile-libabigail:
+ @if [ $(current_stage) = stageprofile ]; then \
+ [ -f $(HOST_SUBDIR)/libabigail/Makefile ] || exit 0; \
+ else \
+ [ -f $(HOST_SUBDIR)/stageprofile-libabigail/Makefile ] || exit 0; \
+ $(MAKE) stageprofile-start; \
+ fi; \
+ cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(EXTRA_HOST_FLAGS) $(POSTSTAGE1_FLAGS_TO_PASS) V=1 clean
+@endif libabigail-bootstrap
+
+
+.PHONY: all-stagefeedback-libabigail maybe-all-stagefeedback-libabigail
+.PHONY: clean-stagefeedback-libabigail maybe-clean-stagefeedback-libabigail
+maybe-all-stagefeedback-libabigail:
+maybe-clean-stagefeedback-libabigail:
+@if libabigail-bootstrap
+maybe-all-stagefeedback-libabigail: all-stagefeedback-libabigail
+all-stagefeedback: all-stagefeedback-libabigail
+TARGET-stagefeedback-libabigail = $(TARGET-libabigail)
+all-stagefeedback-libabigail: configure-stagefeedback-libabigail
+ @[ $(current_stage) = stagefeedback ] || $(MAKE) stagefeedback-start
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ TFLAGS="$(STAGEfeedback_TFLAGS)"; \
+ $(HOST_EXPORTS) \
+ $(POSTSTAGE1_HOST_EXPORTS) \
+ cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) \
+ CFLAGS="$(STAGEfeedback_CFLAGS)" \
+ CXXFLAGS="$(STAGEfeedback_CXXFLAGS)" \
+ LIBCFLAGS="$(STAGEfeedback_CFLAGS)" \
+ CFLAGS_FOR_TARGET="$(CFLAGS_FOR_TARGET)" \
+ CXXFLAGS_FOR_TARGET="$(CXXFLAGS_FOR_TARGET)" \
+ LIBCFLAGS_FOR_TARGET="$(LIBCFLAGS_FOR_TARGET)" \
+ $(EXTRA_HOST_FLAGS) $(POSTSTAGE1_FLAGS_TO_PASS) V=1 \
+ TFLAGS="$(STAGEfeedback_TFLAGS)" \
+ $(TARGET-stagefeedback-libabigail)
+
+maybe-clean-stagefeedback-libabigail: clean-stagefeedback-libabigail
+clean-stagefeedback: clean-stagefeedback-libabigail
+clean-stagefeedback-libabigail:
+ @if [ $(current_stage) = stagefeedback ]; then \
+ [ -f $(HOST_SUBDIR)/libabigail/Makefile ] || exit 0; \
+ else \
+ [ -f $(HOST_SUBDIR)/stagefeedback-libabigail/Makefile ] || exit 0; \
+ $(MAKE) stagefeedback-start; \
+ fi; \
+ cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(EXTRA_HOST_FLAGS) $(POSTSTAGE1_FLAGS_TO_PASS) V=1 clean
+@endif libabigail-bootstrap
+
+
+
+
+
+.PHONY: check-libabigail maybe-check-libabigail
+maybe-check-libabigail:
+@if libabigail
+maybe-check-libabigail: check-libabigail
+
+check-libabigail:
+ @: $(MAKE); $(unstage)
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(HOST_EXPORTS) \
+ (cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(FLAGS_TO_PASS) V=1 check)
+
+@endif libabigail
+
+.PHONY: install-libabigail maybe-install-libabigail
+maybe-install-libabigail:
+@if libabigail
+maybe-install-libabigail: install-libabigail
+
+install-libabigail:
+
+@endif libabigail
+
+.PHONY: install-strip-libabigail maybe-install-strip-libabigail
+maybe-install-strip-libabigail:
+@if libabigail
+maybe-install-strip-libabigail: install-strip-libabigail
+
+install-strip-libabigail:
+
+@endif libabigail
+
+# Other targets (info, dvi, pdf, etc.)
+
+.PHONY: maybe-info-libabigail info-libabigail
+maybe-info-libabigail:
+@if libabigail
+maybe-info-libabigail: info-libabigail
+
+info-libabigail: \
+ configure-libabigail
+ @[ -f ./libabigail/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(HOST_EXPORTS) \
+ for flag in $(EXTRA_HOST_FLAGS) V=1; do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in libabigail" ; \
+ (cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" "WINDMC=$${WINDMC}" \
+ info) \
+ || exit 1
+
+@endif libabigail
+
+.PHONY: maybe-dvi-libabigail dvi-libabigail
+maybe-dvi-libabigail:
+@if libabigail
+maybe-dvi-libabigail: dvi-libabigail
+
+dvi-libabigail: \
+ configure-libabigail
+ @[ -f ./libabigail/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(HOST_EXPORTS) \
+ for flag in $(EXTRA_HOST_FLAGS) V=1; do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in libabigail" ; \
+ (cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" "WINDMC=$${WINDMC}" \
+ dvi) \
+ || exit 1
+
+@endif libabigail
+
+.PHONY: maybe-pdf-libabigail pdf-libabigail
+maybe-pdf-libabigail:
+@if libabigail
+maybe-pdf-libabigail: pdf-libabigail
+
+pdf-libabigail: \
+ configure-libabigail
+ @[ -f ./libabigail/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(HOST_EXPORTS) \
+ for flag in $(EXTRA_HOST_FLAGS) V=1; do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing pdf in libabigail" ; \
+ (cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" "WINDMC=$${WINDMC}" \
+ pdf) \
+ || exit 1
+
+@endif libabigail
+
+.PHONY: maybe-html-libabigail html-libabigail
+maybe-html-libabigail:
+@if libabigail
+maybe-html-libabigail: html-libabigail
+
+html-libabigail: \
+ configure-libabigail
+ @[ -f ./libabigail/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(HOST_EXPORTS) \
+ for flag in $(EXTRA_HOST_FLAGS) V=1; do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing html in libabigail" ; \
+ (cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" "WINDMC=$${WINDMC}" \
+ html) \
+ || exit 1
+
+@endif libabigail
+
+.PHONY: maybe-TAGS-libabigail TAGS-libabigail
+maybe-TAGS-libabigail:
+@if libabigail
+maybe-TAGS-libabigail: TAGS-libabigail
+
+TAGS-libabigail: \
+ configure-libabigail
+ @[ -f ./libabigail/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(HOST_EXPORTS) \
+ for flag in $(EXTRA_HOST_FLAGS) V=1; do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in libabigail" ; \
+ (cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" "WINDMC=$${WINDMC}" \
+ TAGS) \
+ || exit 1
+
+@endif libabigail
+
+.PHONY: maybe-install-info-libabigail install-info-libabigail
+maybe-install-info-libabigail:
+@if libabigail
+maybe-install-info-libabigail: install-info-libabigail
+
+install-info-libabigail: \
+ configure-libabigail \
+ info-libabigail
+ @[ -f ./libabigail/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(HOST_EXPORTS) \
+ for flag in $(EXTRA_HOST_FLAGS) V=1; do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in libabigail" ; \
+ (cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" "WINDMC=$${WINDMC}" \
+ install-info) \
+ || exit 1
+
+@endif libabigail
+
+.PHONY: maybe-install-pdf-libabigail install-pdf-libabigail
+maybe-install-pdf-libabigail:
+@if libabigail
+maybe-install-pdf-libabigail: install-pdf-libabigail
+
+install-pdf-libabigail: \
+ configure-libabigail \
+ pdf-libabigail
+ @[ -f ./libabigail/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(HOST_EXPORTS) \
+ for flag in $(EXTRA_HOST_FLAGS) V=1; do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-pdf in libabigail" ; \
+ (cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" "WINDMC=$${WINDMC}" \
+ install-pdf) \
+ || exit 1
+
+@endif libabigail
+
+.PHONY: maybe-install-html-libabigail install-html-libabigail
+maybe-install-html-libabigail:
+@if libabigail
+maybe-install-html-libabigail: install-html-libabigail
+
+install-html-libabigail: \
+ configure-libabigail \
+ html-libabigail
+ @[ -f ./libabigail/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(HOST_EXPORTS) \
+ for flag in $(EXTRA_HOST_FLAGS) V=1; do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-html in libabigail" ; \
+ (cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" "WINDMC=$${WINDMC}" \
+ install-html) \
+ || exit 1
+
+@endif libabigail
+
+.PHONY: maybe-installcheck-libabigail installcheck-libabigail
+maybe-installcheck-libabigail:
+@if libabigail
+maybe-installcheck-libabigail: installcheck-libabigail
+
+installcheck-libabigail: \
+ configure-libabigail
+ @[ -f ./libabigail/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(HOST_EXPORTS) \
+ for flag in $(EXTRA_HOST_FLAGS) V=1; do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in libabigail" ; \
+ (cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" "WINDMC=$${WINDMC}" \
+ installcheck) \
+ || exit 1
+
+@endif libabigail
+
+.PHONY: maybe-mostlyclean-libabigail mostlyclean-libabigail
+maybe-mostlyclean-libabigail:
+@if libabigail
+maybe-mostlyclean-libabigail: mostlyclean-libabigail
+
+mostlyclean-libabigail:
+ @[ -f ./libabigail/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(HOST_EXPORTS) \
+ for flag in $(EXTRA_HOST_FLAGS) V=1; do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in libabigail" ; \
+ (cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" "WINDMC=$${WINDMC}" \
+ mostlyclean) \
+ || exit 1
+
+@endif libabigail
+
+.PHONY: maybe-clean-libabigail clean-libabigail
+maybe-clean-libabigail:
+@if libabigail
+maybe-clean-libabigail: clean-libabigail
+
+clean-libabigail:
+ @[ -f ./libabigail/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(HOST_EXPORTS) \
+ for flag in $(EXTRA_HOST_FLAGS) V=1; do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in libabigail" ; \
+ (cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" "WINDMC=$${WINDMC}" \
+ clean) \
+ || exit 1
+
+@endif libabigail
+
+.PHONY: maybe-distclean-libabigail distclean-libabigail
+maybe-distclean-libabigail:
+@if libabigail
+maybe-distclean-libabigail: distclean-libabigail
+
+distclean-libabigail:
+ @[ -f ./libabigail/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(HOST_EXPORTS) \
+ for flag in $(EXTRA_HOST_FLAGS) V=1; do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in libabigail" ; \
+ (cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" "WINDMC=$${WINDMC}" \
+ distclean) \
+ || exit 1
+
+@endif libabigail
+
+.PHONY: maybe-maintainer-clean-libabigail maintainer-clean-libabigail
+maybe-maintainer-clean-libabigail:
+@if libabigail
+maybe-maintainer-clean-libabigail: maintainer-clean-libabigail
+
+maintainer-clean-libabigail:
+ @[ -f ./libabigail/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(HOST_EXPORTS) \
+ for flag in $(EXTRA_HOST_FLAGS) V=1; do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in libabigail" ; \
+ (cd $(HOST_SUBDIR)/libabigail && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" "WINDMC=$${WINDMC}" \
+ maintainer-clean) \
+ || exit 1
+
+@endif libabigail
+
+
+
.PHONY: configure-libelf maybe-configure-libelf
maybe-configure-libelf:
@if gcc-bootstrap
@@ -43466,6 +44358,11 @@ stage1-start::
mkdir stage1-cloog; \
mv stage1-cloog cloog
@endif cloog
+@if libabigail
+ @cd $(HOST_SUBDIR); [ -d stage1-libabigail ] || \
+ mkdir stage1-libabigail; \
+ mv stage1-libabigail libabigail
+@endif libabigail
@if libelf
@cd $(HOST_SUBDIR); [ -d stage1-libelf ] || \
mkdir stage1-libelf; \
@@ -43571,6 +44468,11 @@ stage1-end::
cd $(HOST_SUBDIR); mv cloog stage1-cloog ; \
fi
@endif cloog
+@if libabigail
+ @if test -d $(HOST_SUBDIR)/libabigail ; then \
+ cd $(HOST_SUBDIR); mv libabigail stage1-libabigail ; \
+ fi
+@endif libabigail
@if libelf
@if test -d $(HOST_SUBDIR)/libelf ; then \
cd $(HOST_SUBDIR); mv libelf stage1-libelf ; \
@@ -43729,6 +44631,12 @@ stage2-start::
mv stage2-cloog cloog ; \
mv stage1-cloog prev-cloog || test -f stage1-lean
@endif cloog
+@if libabigail
+ @cd $(HOST_SUBDIR); [ -d stage2-libabigail ] || \
+ mkdir stage2-libabigail; \
+ mv stage2-libabigail libabigail ; \
+ mv stage1-libabigail prev-libabigail || test -f stage1-lean
+@endif libabigail
@if libelf
@cd $(HOST_SUBDIR); [ -d stage2-libelf ] || \
mkdir stage2-libelf; \
@@ -43855,6 +44763,12 @@ stage2-end::
mv prev-cloog stage1-cloog ; : ; \
fi
@endif cloog
+@if libabigail
+ @if test -d $(HOST_SUBDIR)/libabigail ; then \
+ cd $(HOST_SUBDIR); mv libabigail stage2-libabigail ; \
+ mv prev-libabigail stage1-libabigail ; : ; \
+ fi
+@endif libabigail
@if libelf
@if test -d $(HOST_SUBDIR)/libelf ; then \
cd $(HOST_SUBDIR); mv libelf stage2-libelf ; \
@@ -44047,6 +44961,12 @@ stage3-start::
mv stage3-cloog cloog ; \
mv stage2-cloog prev-cloog || test -f stage2-lean
@endif cloog
+@if libabigail
+ @cd $(HOST_SUBDIR); [ -d stage3-libabigail ] || \
+ mkdir stage3-libabigail; \
+ mv stage3-libabigail libabigail ; \
+ mv stage2-libabigail prev-libabigail || test -f stage2-lean
+@endif libabigail
@if libelf
@cd $(HOST_SUBDIR); [ -d stage3-libelf ] || \
mkdir stage3-libelf; \
@@ -44173,6 +45093,12 @@ stage3-end::
mv prev-cloog stage2-cloog ; : ; \
fi
@endif cloog
+@if libabigail
+ @if test -d $(HOST_SUBDIR)/libabigail ; then \
+ cd $(HOST_SUBDIR); mv libabigail stage3-libabigail ; \
+ mv prev-libabigail stage2-libabigail ; : ; \
+ fi
+@endif libabigail
@if libelf
@if test -d $(HOST_SUBDIR)/libelf ; then \
cd $(HOST_SUBDIR); mv libelf stage3-libelf ; \
@@ -44421,6 +45347,12 @@ stage4-start::
mv stage4-cloog cloog ; \
mv stage3-cloog prev-cloog || test -f stage3-lean
@endif cloog
+@if libabigail
+ @cd $(HOST_SUBDIR); [ -d stage4-libabigail ] || \
+ mkdir stage4-libabigail; \
+ mv stage4-libabigail libabigail ; \
+ mv stage3-libabigail prev-libabigail || test -f stage3-lean
+@endif libabigail
@if libelf
@cd $(HOST_SUBDIR); [ -d stage4-libelf ] || \
mkdir stage4-libelf; \
@@ -44547,6 +45479,12 @@ stage4-end::
mv prev-cloog stage3-cloog ; : ; \
fi
@endif cloog
+@if libabigail
+ @if test -d $(HOST_SUBDIR)/libabigail ; then \
+ cd $(HOST_SUBDIR); mv libabigail stage4-libabigail ; \
+ mv prev-libabigail stage3-libabigail ; : ; \
+ fi
+@endif libabigail
@if libelf
@if test -d $(HOST_SUBDIR)/libelf ; then \
cd $(HOST_SUBDIR); mv libelf stage4-libelf ; \
@@ -44783,6 +45721,12 @@ stageprofile-start::
mv stageprofile-cloog cloog ; \
mv stage1-cloog prev-cloog || test -f stage1-lean
@endif cloog
+@if libabigail
+ @cd $(HOST_SUBDIR); [ -d stageprofile-libabigail ] || \
+ mkdir stageprofile-libabigail; \
+ mv stageprofile-libabigail libabigail ; \
+ mv stage1-libabigail prev-libabigail || test -f stage1-lean
+@endif libabigail
@if libelf
@cd $(HOST_SUBDIR); [ -d stageprofile-libelf ] || \
mkdir stageprofile-libelf; \
@@ -44909,6 +45853,12 @@ stageprofile-end::
mv prev-cloog stage1-cloog ; : ; \
fi
@endif cloog
+@if libabigail
+ @if test -d $(HOST_SUBDIR)/libabigail ; then \
+ cd $(HOST_SUBDIR); mv libabigail stageprofile-libabigail ; \
+ mv prev-libabigail stage1-libabigail ; : ; \
+ fi
+@endif libabigail
@if libelf
@if test -d $(HOST_SUBDIR)/libelf ; then \
cd $(HOST_SUBDIR); mv libelf stageprofile-libelf ; \
@@ -45078,6 +46028,12 @@ stagefeedback-start::
mv stagefeedback-cloog cloog ; \
mv stageprofile-cloog prev-cloog || test -f stageprofile-lean
@endif cloog
+@if libabigail
+ @cd $(HOST_SUBDIR); [ -d stagefeedback-libabigail ] || \
+ mkdir stagefeedback-libabigail; \
+ mv stagefeedback-libabigail libabigail ; \
+ mv stageprofile-libabigail prev-libabigail || test -f stageprofile-lean
+@endif libabigail
@if libelf
@cd $(HOST_SUBDIR); [ -d stagefeedback-libelf ] || \
mkdir stagefeedback-libelf; \
@@ -45204,6 +46160,12 @@ stagefeedback-end::
mv prev-cloog stageprofile-cloog ; : ; \
fi
@endif cloog
+@if libabigail
+ @if test -d $(HOST_SUBDIR)/libabigail ; then \
+ cd $(HOST_SUBDIR); mv libabigail stagefeedback-libabigail ; \
+ mv prev-libabigail stageprofile-libabigail ; : ; \
+ fi
+@endif libabigail
@if libelf
@if test -d $(HOST_SUBDIR)/libelf ; then \
cd $(HOST_SUBDIR); mv libelf stagefeedback-libelf ; \
diff --git a/Makefile.tpl b/Makefile.tpl
index 3233a788d8d..192188fa480 100644
--- a/Makefile.tpl
+++ b/Makefile.tpl
@@ -225,6 +225,8 @@ HOST_EXPORTS = \
ISLINC="$(HOST_ISLINC)"; export ISLINC; \
CLOOGLIBS="$(HOST_CLOOGLIBS)"; export CLOOGLIBS; \
CLOOGINC="$(HOST_CLOOGINC)"; export CLOOGINC; \
+ ABIGAILLIBS="$(HOST_ABIGAILLIBS)"; export ABIGAILLIBS; \
+ ABIGAILINC="$(HOST_ABIGAILINC)"; export ABIGAILINC; \
LIBELFLIBS="$(HOST_LIBELFLIBS)" ; export LIBELFLIBS; \
LIBELFINC="$(HOST_LIBELFINC)" ; export LIBELFINC; \
@if gcc-bootstrap
@@ -319,6 +321,10 @@ HOST_ISLINC = @islinc@
HOST_CLOOGLIBS = @clooglibs@
HOST_CLOOGINC = @clooginc@
+# Where to find libabigail
+HOST_ABIGAILLIBS = @abigaillibs@
+HOST_ABIGAILINC = @abigailinc@
+
# Where to find libelf
HOST_LIBELFLIBS = @libelflibs@
HOST_LIBELFINC = @libelfinc@
diff --git a/config/abigail.m4 b/config/abigail.m4
new file mode 100644
index 00000000000..b4db85e0467
--- /dev/null
+++ b/config/abigail.m4
@@ -0,0 +1,177 @@
+# Copyright (C) 2013 Free Software Foundation, Inc.
+#
+# This file is part of the GNU Application Binary Interface Generic
+# Analysis and Instrumentation Library (libabigail). This library is
+# free software; you can redistribute it and/or modify it under the
+# terms of the GNU General Public License as published by the Free
+# Software Foundation; either version 3, or (at your option) any
+# later version.
+#
+# This library is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# Under Section 7 of GPL version 3, you are granted additional
+# permissions described in the GCC Runtime Library Exception, version
+# 3.1, as published by the Free Software Foundation.
+#
+# You should have received a copy of the GNU General Public License
+# and a copy of the GCC Runtime Library Exception along with this
+# program; see the files COPYING3 and COPYING.RUNTIME respectively.
+# If not, see <http://www.gnu.org/licenses/>.
+
+# ABIGAIL_INIT
+#
+# Handle the detection of the libabigail header and library files on
+# the system. If these are present, set the 'abigailinc' variable to
+# the compiler option necessary to locate the headers of the library;
+# also set the 'abigaillibs' variable to the compiler/linker option
+# necessary to locate the library.
+#
+# Note that this macro defines the handling of --with-abigail,
+# --with-abigail-include, --with-abigail-lib and
+# --enable-abigail-version-check switches to the configure script.
+#
+# If libabigail has been found, this macro sets the variable
+# HAVE_LIBABIGAIL to 'yes', otherwise, it sets it to 'no'.
+AC_DEFUN([ABIGAIL_INIT],
+[
+ AC_ARG_WITH([abigail],
+ [AS_HELP_STRING([--with-abigail],
+ [Prefix directory for abigail library])],
+ [],
+ [])
+
+ AC_ARG_WITH([abigail-include],
+ [AS_HELP_STRING([--with-abigail-include],
+ [Directory for installed abigail include files])],
+ [],
+ [])
+
+ AC_ARG_WITH([abigail-lib],
+ [AS_HELP_STRING([--with-abigail-lib],
+ [Directory for installed abigail library])],
+ [],
+ [])
+
+ AC_ARG_ENABLE(abigail-version-check,
+ [AS_HELP_STRING([--enable-abigail-version-check],
+ [Enable check for libabigail version])],
+ [ENABLE_ABIGAIL_VERSION_CHECK=$enableval],
+ [ENABLE_ABIGAIL_VERSION_CHECK=yes])
+
+ if test x$with_abigail != x -a x$with_abigail != xno; then
+ abigailinc="-I$with_abigail/include"
+ abigaillibs="-L$with_abigail/lib"
+ found_abigail_lib=yes
+ found_abigail_inc=yes
+ fi
+
+ if test x$with_abigail_include != x -a x$with_abigail != xno; then
+ abigailinc="-I$with_abigail_include"
+ found_abigail_inc=yes
+ fi
+
+ if test x$with_abigail_lib != x -a x$with_abigail != xno; then
+ abigaillibs="-L$with_abigail_lib"
+ found_abigail_lib=yes
+ fi
+
+ if test x$abigaillibs = x; then
+ AC_CHECK_LIB(abigail, abigail_get_library_version,
+ [found_abigail_lib=yes], [], [])
+ fi
+
+ if test x$found_abigail_lib = xyes; then
+ abigaillibs="$abigaillibs -labigail"
+ fi
+
+ if test x$abigailinc = x; then
+ AC_LANG_PUSH(C++)
+ AC_CHECK_HEADER([libabigail/abg-version.h],
+ [found_abigail_inc=yes], [], [])
+ AC_LANG_POP(C++)
+ fi
+
+ if test x$found_abigail_lib = xyes -a x$found_abigail_inc = xyes; then
+ HAVE_LIBABIGAIL=yes
+ else
+ HAVE_LIBABIGAIL=no
+ fi
+
+ #Test whether libabigail is in the gcc source tree.
+ if test x$HAVE_LIBABIGAIL != xyes; then
+ if test -d $srcdir/libabigail -a -f $srcdir/gcc/gcc.c; then
+ abigaillibs='-L$$r/$(HOST_SUBDIR)/libabigail/src/'"${lt_cv_objdir} ${abigaillibs}"
+ abigailinc='-I${srcdir}/libabigail/src '"${abigailinc}"
+ found_abigail_lib=yes
+ found_abigail_inc=yes
+ HAVE_LIBABIGAIL=yes
+ AC_MSG_WARN([using in-tree libabigail, disabling version check]);
+ ENABLE_ABIGAIL_VERSION_CHECK=no
+ fi
+ fi
+]
+)
+
+# IF_ABIGAIL_PRESENT(ACTION-IF-PRESENT)
+AC_DEFUN([IF_ABIGAIL_PRESENT],
+[
+ AC_REQUIRE([ABIGAIL_INIT])
+
+ if test x$HAVE_LIBABIGAIL = xyes; then
+ $1
+ fi
+]
+)
+
+# IF_ABIGAIL_NOT_PRESENT(ACTION-IF-NOT-PRESENT)
+AC_DEFUN([IF_ABIGAIL_NOT_PRESENT],
+[
+ AC_REQUIRE([ABIGAIL_INIT])
+ if test x$HAVE_LIBABIGAIL != xyes; then
+ $1
+ fi
+]
+)
+
+# ABIGAIL_CHECK_VERSION(MAJOR, MINOR)
+#
+# Test the whether the found major and minor version numbers of the
+# found abigail library is compatible with the MAJOR.MINOR version
+# number given in argument. The result of the test ('yes' or 'no') is
+# put in the variable has_right_abigail_version.
+AC_DEFUN([ABIGAIL_CHECK_VERSION],
+[
+ AC_REQUIRE([ABIGAIL_INIT])
+
+ if test x$ENABLE_ABIGAIL_VERSION_CHECK = xyes; then
+ _abigail_saved_CXXFLAGS=$CXXFLAGLS
+ _abigail_saved_LDFLAGS=$LDFLAGS
+
+ CXXFLAGS="$abigailinc"
+ LDFLAGS="$abigaillibs"
+
+ AC_MSG_CHECKING([for version $1.$2 of libabigail])
+ AC_LANG_PUSH(C++)
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([#include "libabigail/abg-version.h"],
+ [#if ABIGAIL_VERSION_MAJOR != $1 || ABIGAIL_VERSION_MINOR < $2
+ choke here
+ #endif
+ ])
+ ],
+ has_right_abigail_version=yes,
+ has_right_abigail_version=no)
+ AC_LANG_POP(C++)
+ AC_MSG_RESULT([$has_right_abigail_version])
+
+ CXXFLAGS=$_abigail_saved_CXXFLAGS
+ LDFLAGS=$_abigail_saved_LDFLAGS
+ else
+ # Version checking was disabled, so assume we have the right
+ # version of libabigail.
+ has_right_abigail_version=yes
+ fi
+]
+)
diff --git a/configure b/configure
index e161cada19e..0b600475dba 100755
--- a/configure
+++ b/configure
@@ -553,6 +553,42 @@ PACKAGE_URL=
ac_unique_file="move-if-change"
enable_option_checking=no
+# Factoring default headers for most tests.
+ac_includes_default="\
+#include <stdio.h>
+#ifdef HAVE_SYS_TYPES_H
+# include <sys/types.h>
+#endif
+#ifdef HAVE_SYS_STAT_H
+# include <sys/stat.h>
+#endif
+#ifdef STDC_HEADERS
+# include <stdlib.h>
+# include <stddef.h>
+#else
+# ifdef HAVE_STDLIB_H
+# include <stdlib.h>
+# endif
+#endif
+#ifdef HAVE_STRING_H
+# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
+# include <memory.h>
+# endif
+# include <string.h>
+#endif
+#ifdef HAVE_STRINGS_H
+# include <strings.h>
+#endif
+#ifdef HAVE_INTTYPES_H
+# include <inttypes.h>
+#endif
+#ifdef HAVE_STDINT_H
+# include <stdint.h>
+#endif
+#ifdef HAVE_UNISTD_H
+# include <unistd.h>
+#endif"
+
ac_subst_vars='LTLIBOBJS
LIBOBJS
compare_exclusions
@@ -643,6 +679,11 @@ DEBUG_PREFIX_CFLAGS_FOR_TARGET
SYSROOT_CFLAGS_FOR_TARGET
stage1_languages
extra_host_libiberty_configure_flags
+abigailinc
+abigaillibs
+EGREP
+GREP
+CXXCPP
clooginc
clooglibs
islinc
@@ -776,6 +817,11 @@ enable_isl_version_check
with_cloog_include
with_cloog_lib
enable_cloog_version_check
+enable_abi_instrumentation
+with_abigail
+with_abigail_include
+with_abigail_lib
+enable_abigail_version_check
enable_lto
enable_stage1_languages
enable_objc_gc
@@ -799,6 +845,7 @@ CPPFLAGS
CXX
CXXFLAGS
CCC
+CXXCPP
build_configargs
host_configargs
target_configargs
@@ -1473,6 +1520,10 @@ Optional Features:
disable check for ISL version
--disable-cloog-version-check
disable check for CLooG version
+ --enable-abi-instrumentation
+ enable abi instrumentation generation
+ --enable-abigail-version-check
+ Enable check for libabigail version
--enable-lto enable link time optimization support
--enable-stage1-languages[=all]
choose additional languages to build during stage1.
@@ -1536,6 +1587,9 @@ Optional Packages:
Specify directory for installed CLooG include files
--with-cloog-lib=PATH Specify the directory for the installed CLooG
library
+ --with-abigail Prefix directory for abigail library
+ --with-abigail-include Directory for installed abigail include files
+ --with-abigail-lib Directory for installed abigail library
--with-build-sysroot=SYSROOT
use sysroot as the system root during the build
--with-debug-prefix-map='A=B C=D ...'
@@ -1555,6 +1609,7 @@ Some influential environment variables:
you have headers in a nonstandard directory <include dir>
CXX C++ compiler command
CXXFLAGS C++ compiler flags
+ CXXCPP C++ preprocessor
build_configargs
additional configure arguments for build directories
host_configargs
@@ -1900,6 +1955,203 @@ fi
return $ac_retval
} # ac_fn_c_try_run
+
+# ac_fn_cxx_try_cpp LINENO
+# ------------------------
+# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
+ac_fn_cxx_try_cpp ()
+{
+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+ if { { ac_try="$ac_cpp conftest.$ac_ext"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
+$as_echo "$ac_try_echo"; } >&5
+ (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
+ ac_status=$?
+ if test -s conftest.err; then
+ grep -v '^ *+' conftest.err >conftest.er1
+ cat conftest.er1 >&5
+ mv -f conftest.er1 conftest.err
+ fi
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; } >/dev/null && {
+ test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
+ test ! -s conftest.err
+ }; then :
+ ac_retval=0
+else
+ $as_echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ ac_retval=1
+fi
+ eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+ return $ac_retval
+
+} # ac_fn_cxx_try_cpp
+
+# ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES
+# ---------------------------------------------------------
+# Tests whether HEADER exists, giving a warning if it cannot be compiled using
+# the include files in INCLUDES and setting the cache variable VAR
+# accordingly.
+ac_fn_cxx_check_header_mongrel ()
+{
+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+ if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
+$as_echo_n "checking for $2... " >&6; }
+if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+ $as_echo_n "(cached) " >&6
+fi
+eval ac_res=\$$3
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
+$as_echo "$ac_res" >&6; }
+else
+ # Is the header compilable?
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
+$as_echo_n "checking $2 usability... " >&6; }
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+$4
+#include <$2>
+_ACEOF
+if ac_fn_cxx_try_compile "$LINENO"; then :
+ ac_header_compiler=yes
+else
+ ac_header_compiler=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
+$as_echo "$ac_header_compiler" >&6; }
+
+# Is the header present?
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
+$as_echo_n "checking $2 presence... " >&6; }
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+#include <$2>
+_ACEOF
+if ac_fn_cxx_try_cpp "$LINENO"; then :
+ ac_header_preproc=yes
+else
+ ac_header_preproc=no
+fi
+rm -f conftest.err conftest.$ac_ext
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
+$as_echo "$ac_header_preproc" >&6; }
+
+# So? What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #((
+ yes:no: )
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
+$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
+$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
+ ;;
+ no:yes:* )
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
+$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
+$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
+$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
+$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
+$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
+ ;;
+esac
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
+$as_echo_n "checking for $2... " >&6; }
+if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+ $as_echo_n "(cached) " >&6
+else
+ eval "$3=\$ac_header_compiler"
+fi
+eval ac_res=\$$3
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
+$as_echo "$ac_res" >&6; }
+fi
+ eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+
+} # ac_fn_cxx_check_header_mongrel
+
+# ac_fn_cxx_try_run LINENO
+# ------------------------
+# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
+# that executables *can* be run.
+ac_fn_cxx_try_run ()
+{
+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+ if { { ac_try="$ac_link"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
+$as_echo "$ac_try_echo"; } >&5
+ (eval "$ac_link") 2>&5
+ ac_status=$?
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
+ { { case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
+$as_echo "$ac_try_echo"; } >&5
+ (eval "$ac_try") 2>&5
+ ac_status=$?
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; }; then :
+ ac_retval=0
+else
+ $as_echo "$as_me: program exited with status $ac_status" >&5
+ $as_echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ ac_retval=$ac_status
+fi
+ rm -rf conftest.dSYM conftest_ipa8_conftest.oo
+ eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+ return $ac_retval
+
+} # ac_fn_cxx_try_run
+
+# ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES
+# ---------------------------------------------------------
+# Tests whether HEADER exists and can be compiled using the include files in
+# INCLUDES, setting the cache variable VAR accordingly.
+ac_fn_cxx_check_header_compile ()
+{
+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
+$as_echo_n "checking for $2... " >&6; }
+if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+ $as_echo_n "(cached) " >&6
+else
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+$4
+#include <$2>
+_ACEOF
+if ac_fn_cxx_try_compile "$LINENO"; then :
+ eval "$3=yes"
+else
+ eval "$3=no"
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+eval ac_res=\$$3
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
+$as_echo "$ac_res" >&6; }
+ eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+
+} # ac_fn_cxx_check_header_compile
cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
@@ -2746,7 +2998,7 @@ build_tools="build-texinfo build-flex build-bison build-m4 build-fixincludes"
# these libraries are used by various programs built for the host environment
#
-host_libs="intl libiberty opcodes bfd readline tcl tk itcl libgui zlib libbacktrace libcpp libdecnumber gmp mpfr mpc isl cloog libelf libiconv"
+host_libs="intl libiberty opcodes bfd readline tcl tk itcl libgui zlib libbacktrace libcpp libdecnumber gmp mpfr mpc isl cloog libabigail libelf libiconv"
# these tools are built for the host environment
# Note, the powerpc-eabi build depends on sim occurring before gdb in order to
@@ -6161,6 +6413,621 @@ fi
+# Check for a system's libabigail presence or for an in-tree one. And
+# then, check for ABI Instrumentation support.
+# Check whether --enable-abi-instrumentation was given.
+if test "${enable_abi_instrumentation+set}" = set; then :
+ enableval=$enable_abi_instrumentation; enable_abi_instr=$enableval
+else
+ enable_abi_instr=yes
+fi
+
+
+if test x$enable_abi_instr = xyes; then
+ ac_ext=cpp
+ac_cpp='$CXXCPP $CPPFLAGS'
+ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
+$as_echo_n "checking how to run the C++ preprocessor... " >&6; }
+if test -z "$CXXCPP"; then
+ if test "${ac_cv_prog_CXXCPP+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ # Double quotes because CXXCPP needs to be expanded
+ for CXXCPP in "$CXX -E" "/lib/cpp"
+ do
+ ac_preproc_ok=false
+for ac_cxx_preproc_warn_flag in '' yes
+do
+ # Use a header file that comes with gcc, so configuring glibc
+ # with a fresh cross-compiler works.
+ # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+ # <limits.h> exists even on freestanding compilers.
+ # On the NeXT, cc -E runs the code through the compiler's parser,
+ # not just through cpp. "Syntax error" is here to catch this case.
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+#ifdef __STDC__
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
+ Syntax error
+_ACEOF
+if ac_fn_cxx_try_cpp "$LINENO"; then :
+
+else
+ # Broken: fails on valid input.
+continue
+fi
+rm -f conftest.err conftest.$ac_ext
+
+ # OK, works on sane cases. Now check whether nonexistent headers
+ # can be detected and how.
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+#include <ac_nonexistent.h>
+_ACEOF
+if ac_fn_cxx_try_cpp "$LINENO"; then :
+ # Broken: success on invalid input.
+continue
+else
+ # Passes both tests.
+ac_preproc_ok=:
+break
+fi
+rm -f conftest.err conftest.$ac_ext
+
+done
+# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
+rm -f conftest.err conftest.$ac_ext
+if $ac_preproc_ok; then :
+ break
+fi
+
+ done
+ ac_cv_prog_CXXCPP=$CXXCPP
+
+fi
+ CXXCPP=$ac_cv_prog_CXXCPP
+else
+ ac_cv_prog_CXXCPP=$CXXCPP
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
+$as_echo "$CXXCPP" >&6; }
+ac_preproc_ok=false
+for ac_cxx_preproc_warn_flag in '' yes
+do
+ # Use a header file that comes with gcc, so configuring glibc
+ # with a fresh cross-compiler works.
+ # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+ # <limits.h> exists even on freestanding compilers.
+ # On the NeXT, cc -E runs the code through the compiler's parser,
+ # not just through cpp. "Syntax error" is here to catch this case.
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+#ifdef __STDC__
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
+ Syntax error
+_ACEOF
+if ac_fn_cxx_try_cpp "$LINENO"; then :
+
+else
+ # Broken: fails on valid input.
+continue
+fi
+rm -f conftest.err conftest.$ac_ext
+
+ # OK, works on sane cases. Now check whether nonexistent headers
+ # can be detected and how.
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+#include <ac_nonexistent.h>
+_ACEOF
+if ac_fn_cxx_try_cpp "$LINENO"; then :
+ # Broken: success on invalid input.
+continue
+else
+ # Passes both tests.
+ac_preproc_ok=:
+break
+fi
+rm -f conftest.err conftest.$ac_ext
+
+done
+# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
+rm -f conftest.err conftest.$ac_ext
+if $ac_preproc_ok; then :
+
+else
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error "C++ preprocessor \"$CXXCPP\" fails sanity check
+See \`config.log' for more details." "$LINENO" 5; }
+fi
+
+ac_ext=cpp
+ac_cpp='$CXXCPP $CPPFLAGS'
+ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
+
+
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
+$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
+if test "${ac_cv_path_GREP+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ if test -z "$GREP"; then
+ ac_path_GREP_found=false
+ # Loop through the user's path and test for each of PROGNAME-LIST
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_prog in grep ggrep; do
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
+ { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
+# Check for GNU ac_path_GREP and select it if it is found.
+ # Check for GNU $ac_path_GREP
+case `"$ac_path_GREP" --version 2>&1` in
+*GNU*)
+ ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
+*)
+ ac_count=0
+ $as_echo_n 0123456789 >"conftest.in"
+ while :
+ do
+ cat "conftest.in" "conftest.in" >"conftest.tmp"
+ mv "conftest.tmp" "conftest.in"
+ cp "conftest.in" "conftest.nl"
+ $as_echo 'GREP' >> "conftest.nl"
+ "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
+ diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
+ as_fn_arith $ac_count + 1 && ac_count=$as_val
+ if test $ac_count -gt ${ac_path_GREP_max-0}; then
+ # Best one so far, save it but keep looking for a better one
+ ac_cv_path_GREP="$ac_path_GREP"
+ ac_path_GREP_max=$ac_count
+ fi
+ # 10*(2^10) chars as input seems more than enough
+ test $ac_count -gt 10 && break
+ done
+ rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
+esac
+
+ $ac_path_GREP_found && break 3
+ done
+ done
+ done
+IFS=$as_save_IFS
+ if test -z "$ac_cv_path_GREP"; then
+ as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
+ fi
+else
+ ac_cv_path_GREP=$GREP
+fi
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
+$as_echo "$ac_cv_path_GREP" >&6; }
+ GREP="$ac_cv_path_GREP"
+
+
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
+$as_echo_n "checking for egrep... " >&6; }
+if test "${ac_cv_path_EGREP+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
+ then ac_cv_path_EGREP="$GREP -E"
+ else
+ if test -z "$EGREP"; then
+ ac_path_EGREP_found=false
+ # Loop through the user's path and test for each of PROGNAME-LIST
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_prog in egrep; do
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
+ { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
+# Check for GNU ac_path_EGREP and select it if it is found.
+ # Check for GNU $ac_path_EGREP
+case `"$ac_path_EGREP" --version 2>&1` in
+*GNU*)
+ ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
+*)
+ ac_count=0
+ $as_echo_n 0123456789 >"conftest.in"
+ while :
+ do
+ cat "conftest.in" "conftest.in" >"conftest.tmp"
+ mv "conftest.tmp" "conftest.in"
+ cp "conftest.in" "conftest.nl"
+ $as_echo 'EGREP' >> "conftest.nl"
+ "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
+ diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
+ as_fn_arith $ac_count + 1 && ac_count=$as_val
+ if test $ac_count -gt ${ac_path_EGREP_max-0}; then
+ # Best one so far, save it but keep looking for a better one
+ ac_cv_path_EGREP="$ac_path_EGREP"
+ ac_path_EGREP_max=$ac_count
+ fi
+ # 10*(2^10) chars as input seems more than enough
+ test $ac_count -gt 10 && break
+ done
+ rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
+esac
+
+ $ac_path_EGREP_found && break 3
+ done
+ done
+ done
+IFS=$as_save_IFS
+ if test -z "$ac_cv_path_EGREP"; then
+ as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
+ fi
+else
+ ac_cv_path_EGREP=$EGREP
+fi
+
+ fi
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
+$as_echo "$ac_cv_path_EGREP" >&6; }
+ EGREP="$ac_cv_path_EGREP"
+
+
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
+$as_echo_n "checking for ANSI C header files... " >&6; }
+if test "${ac_cv_header_stdc+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+#include <stdlib.h>
+#include <stdarg.h>
+#include <string.h>
+#include <float.h>
+
+int
+main ()
+{
+
+ ;
+ return 0;
+}
+_ACEOF
+if ac_fn_cxx_try_compile "$LINENO"; then :
+ ac_cv_header_stdc=yes
+else
+ ac_cv_header_stdc=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+if test $ac_cv_header_stdc = yes; then
+ # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+#include <string.h>
+
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+ $EGREP "memchr" >/dev/null 2>&1; then :
+
+else
+ ac_cv_header_stdc=no
+fi
+rm -f conftest*
+
+fi
+
+if test $ac_cv_header_stdc = yes; then
+ # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+#include <stdlib.h>
+
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+ $EGREP "free" >/dev/null 2>&1; then :
+
+else
+ ac_cv_header_stdc=no
+fi
+rm -f conftest*
+
+fi
+
+if test $ac_cv_header_stdc = yes; then
+ # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
+ if test "$cross_compiling" = yes; then :
+ :
+else
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+#include <ctype.h>
+#include <stdlib.h>
+#if ((' ' & 0x0FF) == 0x020)
+# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
+# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
+#else
+# define ISLOWER(c) \
+ (('a' <= (c) && (c) <= 'i') \
+ || ('j' <= (c) && (c) <= 'r') \
+ || ('s' <= (c) && (c) <= 'z'))
+# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
+#endif
+
+#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
+int
+main ()
+{
+ int i;
+ for (i = 0; i < 256; i++)
+ if (XOR (islower (i), ISLOWER (i))
+ || toupper (i) != TOUPPER (i))
+ return 2;
+ return 0;
+}
+_ACEOF
+if ac_fn_cxx_try_run "$LINENO"; then :
+
+else
+ ac_cv_header_stdc=no
+fi
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+ conftest.$ac_objext conftest.beam conftest.$ac_ext
+fi
+
+fi
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
+$as_echo "$ac_cv_header_stdc" >&6; }
+if test $ac_cv_header_stdc = yes; then
+
+$as_echo "#define STDC_HEADERS 1" >>confdefs.h
+
+fi
+
+# On IRIX 5.3, sys/types and inttypes.h are conflicting.
+for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
+ inttypes.h stdint.h unistd.h
+do :
+ as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
+ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
+"
+eval as_val=\$$as_ac_Header
+ if test "x$as_val" = x""yes; then :
+ cat >>confdefs.h <<_ACEOF
+#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
+
+fi
+
+done
+
+
+
+
+# Check whether --with-abigail was given.
+if test "${with_abigail+set}" = set; then :
+ withval=$with_abigail;
+fi
+
+
+
+# Check whether --with-abigail-include was given.
+if test "${with_abigail_include+set}" = set; then :
+ withval=$with_abigail_include;
+fi
+
+
+
+# Check whether --with-abigail-lib was given.
+if test "${with_abigail_lib+set}" = set; then :
+ withval=$with_abigail_lib;
+fi
+
+
+ # Check whether --enable-abigail-version-check was given.
+if test "${enable_abigail_version_check+set}" = set; then :
+ enableval=$enable_abigail_version_check; ENABLE_ABIGAIL_VERSION_CHECK=$enableval
+else
+ ENABLE_ABIGAIL_VERSION_CHECK=yes
+fi
+
+
+ if test x$with_abigail != x -a x$with_abigail != xno; then
+ abigailinc="-I$with_abigail/include"
+ abigaillibs="-L$with_abigail/lib"
+ found_abigail_lib=yes
+ found_abigail_inc=yes
+ fi
+
+ if test x$with_abigail_include != x -a x$with_abigail != xno; then
+ abigailinc="-I$with_abigail_include"
+ found_abigail_inc=yes
+ fi
+
+ if test x$with_abigail_lib != x -a x$with_abigail != xno; then
+ abigaillibs="-L$with_abigail_lib"
+ found_abigail_lib=yes
+ fi
+
+ if test x$abigaillibs = x; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for abigail_get_library_version in -labigail" >&5
+$as_echo_n "checking for abigail_get_library_version in -labigail... " >&6; }
+if test "${ac_cv_lib_abigail_abigail_get_library_version+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-labigail $LIBS"
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+/* Override any GCC internal prototype to avoid an error.
+ Use char because int might match the return type of a GCC
+ builtin and then its argument prototype would still apply. */
+#ifdef __cplusplus
+extern "C"
+#endif
+char abigail_get_library_version ();
+int
+main ()
+{
+return abigail_get_library_version ();
+ ;
+ return 0;
+}
+_ACEOF
+if ac_fn_c_try_link "$LINENO"; then :
+ ac_cv_lib_abigail_abigail_get_library_version=yes
+else
+ ac_cv_lib_abigail_abigail_get_library_version=no
+fi
+rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_abigail_abigail_get_library_version" >&5
+$as_echo "$ac_cv_lib_abigail_abigail_get_library_version" >&6; }
+if test "x$ac_cv_lib_abigail_abigail_get_library_version" = x""yes; then :
+ found_abigail_lib=yes
+fi
+
+ fi
+
+ if test x$found_abigail_lib = xyes; then
+ abigaillibs="$abigaillibs -labigail"
+ fi
+
+ if test x$abigailinc = x; then
+ ac_ext=cpp
+ac_cpp='$CXXCPP $CPPFLAGS'
+ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
+
+ ac_fn_cxx_check_header_mongrel "$LINENO" "libabigail/abg-version.h" "ac_cv_header_libabigail_abg_version_h" "$ac_includes_default"
+if test "x$ac_cv_header_libabigail_abg_version_h" = x""yes; then :
+ found_abigail_inc=yes
+fi
+
+
+ ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
+ fi
+
+ if test x$found_abigail_lib = xyes -a x$found_abigail_inc = xyes; then
+ HAVE_LIBABIGAIL=yes
+ else
+ HAVE_LIBABIGAIL=no
+ fi
+
+ #Test whether libabigail is in the gcc source tree.
+ if test x$HAVE_LIBABIGAIL != xyes; then
+ if test -d $srcdir/libabigail -a -f $srcdir/gcc/gcc.c; then
+ abigaillibs='-L$$r/$(HOST_SUBDIR)/libabigail/src/'"${lt_cv_objdir} ${abigaillibs}"
+ abigailinc='-I${srcdir}/libabigail/src '"${abigailinc}"
+ found_abigail_lib=yes
+ found_abigail_inc=yes
+ HAVE_LIBABIGAIL=yes
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using in-tree libabigail, disabling version check" >&5
+$as_echo "$as_me: WARNING: using in-tree libabigail, disabling version check" >&2;};
+ ENABLE_ABIGAIL_VERSION_CHECK=no
+ fi
+ fi
+
+
+
+
+
+ if test x$ENABLE_ABIGAIL_VERSION_CHECK = xyes; then
+ _abigail_saved_CXXFLAGS=$CXXFLAGLS
+ _abigail_saved_LDFLAGS=$LDFLAGS
+
+ CXXFLAGS="$abigailinc"
+ LDFLAGS="$abigaillibs"
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version 0.1 of libabigail" >&5
+$as_echo_n "checking for version 0.1 of libabigail... " >&6; }
+ ac_ext=cpp
+ac_cpp='$CXXCPP $CPPFLAGS'
+ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
+
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+#include "libabigail/abg-version.h"
+int
+main ()
+{
+#if ABIGAIL_VERSION_MAJOR != 0 || ABIGAIL_VERSION_MINOR < 1
+ choke here
+ #endif
+
+ ;
+ return 0;
+}
+
+_ACEOF
+if ac_fn_cxx_try_compile "$LINENO"; then :
+ has_right_abigail_version=yes
+else
+ has_right_abigail_version=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+ ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_right_abigail_version" >&5
+$as_echo "$has_right_abigail_version" >&6; }
+
+ CXXFLAGS=$_abigail_saved_CXXFLAGS
+ LDFLAGS=$_abigail_saved_LDFLAGS
+ else
+ # Version checking was disabled, so assume we have the right
+ # version of libabigail.
+ has_right_abigail_version=yes
+ fi
+
+
+ if test x$has_right_abigail_version != xyes; then
+ as_fn_error "Unable to find a usable libabigail" "$LINENO" 5
+ else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: abi instrumentation enabled" >&5
+$as_echo "abi instrumentation enabled" >&6; }
+ fi
+else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: abi instrumentation disabled" >&5
+$as_echo "abi instrumentation disabled" >&6; };
+fi
+
+if test x$HAVE_LIBABIGAIL != xyes; then
+ noconfigdirs="$noconfigdirs libabigail"
+fi
+
+
+
# Check for LTO support.
# Check whether --enable-lto was given.
diff --git a/configure.ac b/configure.ac
index bec489fc395..285f5e46534 100644
--- a/configure.ac
+++ b/configure.ac
@@ -30,6 +30,7 @@ m4_include([ltversion.m4])
m4_include([lt~obsolete.m4])
m4_include([config/isl.m4])
m4_include([config/cloog.m4])
+m4_include([config/abigail.m4])
AC_INIT(move-if-change)
AC_PREREQ(2.64)
@@ -133,7 +134,7 @@ build_tools="build-texinfo build-flex build-bison build-m4 build-fixincludes"
# these libraries are used by various programs built for the host environment
#
-host_libs="intl libiberty opcodes bfd readline tcl tk itcl libgui zlib libbacktrace libcpp libdecnumber gmp mpfr mpc isl cloog libelf libiconv"
+host_libs="intl libiberty opcodes bfd readline tcl tk itcl libgui zlib libbacktrace libcpp libdecnumber gmp mpfr mpc isl cloog libabigail libelf libiconv"
# these tools are built for the host environment
# Note, the powerpc-eabi build depends on sim occurring before gdb in order to
@@ -1670,6 +1671,31 @@ AC_SUBST(islinc)
AC_SUBST(clooglibs)
AC_SUBST(clooginc)
+# Check for a system's libabigail presence or for an in-tree one. And
+# then, check for ABI Instrumentation support.
+AC_ARG_ENABLE(abi-instrumentation,
+ [AS_HELP_STRING([--enable-abi-instrumentation],
+ [enable abi instrumentation generation])],
+ [enable_abi_instr=$enableval],
+ [enable_abi_instr=yes])
+
+if test x$enable_abi_instr = xyes; then
+ ABIGAIL_CHECK_VERSION(0,1)
+ if test x$has_right_abigail_version != xyes; then
+ AC_MSG_ERROR([Unable to find a usable libabigail])
+ else
+ AC_MSG_RESULT([abi instrumentation enabled])
+ fi
+else
+ AC_MSG_RESULT([abi instrumentation disabled]);
+fi
+
+if test x$HAVE_LIBABIGAIL != xyes; then
+ noconfigdirs="$noconfigdirs libabigail"
+fi
+
+AC_SUBST(abigaillibs)
+AC_SUBST(abigailinc)
# Check for LTO support.
AC_ARG_ENABLE(lto,
diff --git a/gcc/Makefile.in b/gcc/Makefile.in
index 1a965c18836..8d5f5ceb93f 100644
--- a/gcc/Makefile.in
+++ b/gcc/Makefile.in
@@ -329,6 +329,10 @@ ISLINC = @ISLINC@
CLOOGLIBS = @CLOOGLIBS@
CLOOGINC = @CLOOGINC@
+#How to find libabigail
+ABIGAILLIBS = @ABIGAILLIBS@
+ABIGAILINC = @ABIGAILINC@
+
# Set to 'yes' if the LTO front end is enabled.
enable_lto = @enable_lto@
@@ -1033,7 +1037,7 @@ BUILD_LIBDEPS= $(BUILD_LIBIBERTY)
LIBS = @LIBS@ libcommon.a $(CPPLIB) $(LIBINTL) $(LIBICONV) $(LIBBACKTRACE) \
$(LIBIBERTY) $(LIBDECNUMBER) $(HOST_LIBS)
BACKENDLIBS = $(CLOOGLIBS) $(GMPLIBS) $(PLUGINLIBS) $(HOST_LIBS) \
- $(ZLIB)
+ $(ZLIB) $(ABIGAILLIBS)
# Any system libraries needed just for GNAT.
SYSLIBS = @GNAT_LIBEXC@
@@ -1064,7 +1068,7 @@ BUILD_ERRORS = build/errors.o
INCLUDES = -I. -I$(@D) -I$(srcdir) -I$(srcdir)/$(@D) \
-I$(srcdir)/../include @INCINTL@ \
$(CPPINC) $(GMPINC) $(DECNUMINC) $(BACKTRACEINC) \
- $(CLOOGINC) $(ISLINC)
+ $(CLOOGINC) $(ISLINC) $(ABIGAILINC)
.cc.o .c.o:
$(COMPILER) -c $(ALL_COMPILERFLAGS) $(ALL_CPPFLAGS) $< $(OUTPUT_OPTION)
diff --git a/gcc/config.in b/gcc/config.in
index f122d48579e..f6649a9e53d 100644
--- a/gcc/config.in
+++ b/gcc/config.in
@@ -1619,6 +1619,12 @@
#endif
+/* Defined if libabigail is in use */
+#ifndef USED_FOR_TARGET
+#undef HAVE_abigail
+#endif
+
+
/* Define if cloog is in use. */
#ifndef USED_FOR_TARGET
#undef HAVE_cloog
diff --git a/gcc/configure b/gcc/configure
index 1f03eac6e27..d528f276e7a 100755
--- a/gcc/configure
+++ b/gcc/configure
@@ -602,6 +602,8 @@ ac_subst_vars='LTLIBOBJS
LIBOBJS
enable_plugin
pluginlibs
+ABIGAILINC
+ABIGAILLIBS
CLOOGINC
CLOOGLIBS
ISLINC
@@ -941,7 +943,9 @@ GMPINC
ISLLIBS
ISLINC
CLOOGLIBS
-CLOOGINC'
+CLOOGINC
+ABIGAILLIBS
+ABIGAILINC'
# Initialize some variables set by options.
@@ -1698,6 +1702,8 @@ Some influential environment variables:
ISLINC How to find ISL include files
CLOOGLIBS How to link CLOOG
CLOOGINC How to find CLOOG include files
+ ABIGAILLIBS How to link with libabigail
+ ABIGAILINC How to find libabigail header files
Use these variables to override the choices made by `configure' or to help
it to find libraries and programs with nonstandard names/locations.
@@ -17834,7 +17840,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 17837 "configure"
+#line 17839 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -17940,7 +17946,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 17943 "configure"
+#line 17945 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -27372,6 +27378,14 @@ $as_echo "#define HAVE_cloog 1" >>confdefs.h
fi
+
+
+if test "x${ABIGAILLIBS}" != x; then
+
+$as_echo "#define HAVE_abigail 1" >>confdefs.h
+
+fi
+
# Check for plugin support
# Check whether --enable-plugin was given.
if test "${enable_plugin+set}" = set; then :
diff --git a/gcc/configure.ac b/gcc/configure.ac
index 855affdf152..971ef8c6531 100644
--- a/gcc/configure.ac
+++ b/gcc/configure.ac
@@ -5260,6 +5260,12 @@ if test "x${CLOOGLIBS}" != "x" ; then
AC_DEFINE(HAVE_cloog, 1, [Define if cloog is in use.])
fi
+AC_ARG_VAR(ABIGAILLIBS,[How to link with libabigail])
+AC_ARG_VAR(ABIGAILINC,[How to find libabigail header files])
+if test "x${ABIGAILLIBS}" != x; then
+ AC_DEFINE(HAVE_abigail, 1, [Defined if libabigail is in use])
+fi
+
# Check for plugin support
AC_ARG_ENABLE(plugin,
[AS_HELP_STRING([--enable-plugin], [enable plugin support])],
diff --git a/gcc/cp/Make-lang.in b/gcc/cp/Make-lang.in
index df8ed3ee0d9..9bd53639c89 100644
--- a/gcc/cp/Make-lang.in
+++ b/gcc/cp/Make-lang.in
@@ -80,7 +80,7 @@ CXX_AND_OBJCXX_OBJS = cp/call.o cp/decl.o cp/expr.o cp/pt.o cp/typeck2.o \
cp/typeck.o cp/cvt.o cp/except.o cp/friend.o cp/init.o cp/method.o \
cp/search.o cp/semantics.o cp/tree.o cp/repo.o cp/dump.o cp/optimize.o \
cp/mangle.o cp/cp-objcp-common.o cp/name-lookup.o cp/cxx-pretty-print.o \
- cp/cp-gimplify.o $(CXX_C_OBJS)
+ cp/cp-gimplify.o cp/abi-instr.o $(CXX_C_OBJS)
# Language-specific object files for C++.
CXX_OBJS = cp/cp-lang.o c-family/stub-objc.o $(CXX_AND_OBJCXX_OBJS)
@@ -345,3 +345,5 @@ cp/name-lookup.o: cp/name-lookup.c $(CONFIG_H) $(SYSTEM_H) coretypes.h \
cp/cxx-pretty-print.o: cp/cxx-pretty-print.c $(CXX_PRETTY_PRINT_H) \
$(CONFIG_H) $(SYSTEM_H) $(TM_H) coretypes.h $(CXX_TREE_H) tree-pretty-print.h
+
+cp/abi-instr.o: cp/abi-instr.c $(CONFIG_H)
diff --git a/gcc/cp/abi-instr.c b/gcc/cp/abi-instr.c
new file mode 100644
index 00000000000..493b3a25fee
--- /dev/null
+++ b/gcc/cp/abi-instr.c
@@ -0,0 +1,25 @@
+/* ABI Instrumentation
+ Copyright (C) 2000-2013 Free Software Foundation, Inc.
+ Written by Mark Mitchell <mark@codesourcery.com>.
+
+ This file is part of GCC.
+
+ GCC is free software; you can redistribute it and/or modify it
+ under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 3, or (at your option)
+ any later version.
+
+ GCC is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GCC; see the file COPYING3. If not see
+<http://www.gnu.org/licenses/>. */
+
+#include "config.h"
+#include "abg-reader.h"
+
+#ifdef HAVE_abigail
+#endif /* HAVE_abigail*/