From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2181) id 0CFC23858D20; Thu, 25 Apr 2024 17:52:24 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 0CFC23858D20 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1714067545; bh=Q3QnU5J8BJ5qbATScmCJJVdrstxO5JgExvyfmPjsmq4=; h=From:To:Subject:Date:From; b=m3ponFzBAsm/YPdNKymDXt3z+K1j/4pmy8+GpZbDSFyhKShQjjUufGw8Y4Z+705SX JFeVfde4mQS+QprYMjwCZhAgG9vMY5p91X9aebDfSRjDSaXpAH20UrtOUDDJ0RVlP8 RLta+y5oBQXsmvOe59RPfg90ghmlARprpKuPvzX8= MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" From: Jonathan Wakely To: gcc-cvs@gcc.gnu.org, libstdc++-cvs@gcc.gnu.org Subject: [gcc r13-8649] libstdc++: Add libstdc++_libbacktrace.a to libstdc++exp X-Act-Checkin: gcc X-Git-Author: Jonathan Wakely X-Git-Refname: refs/heads/releases/gcc-13 X-Git-Oldrev: 9c49ab21b5df71cf5e397dfe0f7b97765300ec45 X-Git-Newrev: f3cff718df0cf7590ccf9bc1d8cd17e4e08f1e6d Message-Id: <20240425175225.0CFC23858D20@sourceware.org> Date: Thu, 25 Apr 2024 17:52:24 +0000 (GMT) List-Id: https://gcc.gnu.org/g:f3cff718df0cf7590ccf9bc1d8cd17e4e08f1e6d commit r13-8649-gf3cff718df0cf7590ccf9bc1d8cd17e4e08f1e6d Author: Jonathan Wakely Date: Thu Apr 18 17:26:55 2024 +0100 libstdc++: Add libstdc++_libbacktrace.a to libstdc++exp This completes the fixes to put all experimental symbols into libstdc++exp.a. On trunk the libstdc++_libbacktrace.a was removed completely and its contents aded to libstdc++exp.a instead. We don't want to remove it on the gcc-13 branch because that would break makefiles using it. We can add the contents to libstdc++exp.a and then install a symlink so that using -lstdc++_libbacktrace still works, but links to libstdc++exp.a instead. The libstdc++_libbacktrace.la libtool control file is removed by this change, because I'm pretty sure it's not actually useful, and I don't know whether it should be a symlink to libstdc++exp.la or a regular file that refers to libstdc++_libbacktrace.a. libstdc++-v3/ChangeLog: * src/experimental/Makefile.am (install-exec-local): New target. (uninstall-local): New target. * src/experimental/Makefile.in: Regenerate. * src/libbacktrace/Makefile.am: Build libstdc++_libbacktrace as noinst_LTLIBRARIES so it's only a convenience library. * src/libbacktrace/Makefile.in: Regenerate. Diff: --- libstdc++-v3/src/experimental/Makefile.am | 9 ++++ libstdc++-v3/src/experimental/Makefile.in | 29 +++++++---- libstdc++-v3/src/libbacktrace/Makefile.am | 2 +- libstdc++-v3/src/libbacktrace/Makefile.in | 86 ++++++------------------------- 4 files changed, 44 insertions(+), 82 deletions(-) diff --git a/libstdc++-v3/src/experimental/Makefile.am b/libstdc++-v3/src/experimental/Makefile.am index c5a38d882c2..6536e759abd 100644 --- a/libstdc++-v3/src/experimental/Makefile.am +++ b/libstdc++-v3/src/experimental/Makefile.am @@ -66,6 +66,15 @@ AM_CXXFLAGS = \ AM_MAKEFLAGS = \ "gxx_include_dir=$(gxx_include_dir)" +if ENABLE_BACKTRACE +install-exec-local: + -cd '$(DESTDIR)$(toolexeclibdir)' && \ + $(LN_S) libstdc++exp.a libstdc++_libbacktrace.a +uninstall-local: + -cd '$(DESTDIR)$(toolexeclibdir)' && \ + rm -f libstdc++_libbacktrace.a +endif + # Libtool notes # 1) In general, libtool expects an argument such as `--tag=CXX' when diff --git a/libstdc++-v3/src/experimental/Makefile.in b/libstdc++-v3/src/experimental/Makefile.in index c16083a7fc8..238c96d9f9a 100644 --- a/libstdc++-v3/src/experimental/Makefile.in +++ b/libstdc++-v3/src/experimental/Makefile.in @@ -712,6 +712,8 @@ distclean-generic: maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." +@ENABLE_BACKTRACE_FALSE@install-exec-local: +@ENABLE_BACKTRACE_FALSE@uninstall-local: clean: clean-am clean-am: clean-generic clean-libtool clean-toolexeclibLTLIBRARIES \ @@ -740,7 +742,7 @@ install-dvi: install-dvi-am install-dvi-am: -install-exec-am: install-toolexeclibLTLIBRARIES +install-exec-am: install-exec-local install-toolexeclibLTLIBRARIES install-html: install-html-am @@ -779,7 +781,7 @@ ps: ps-am ps-am: -uninstall-am: uninstall-toolexeclibLTLIBRARIES +uninstall-am: uninstall-local uninstall-toolexeclibLTLIBRARIES .MAKE: install-am install-strip @@ -789,18 +791,25 @@ uninstall-am: uninstall-toolexeclibLTLIBRARIES distclean-libtool distclean-tags dvi dvi-am html html-am info \ info-am install install-am install-data install-data-am \ install-dvi install-dvi-am install-exec install-exec-am \ - install-html install-html-am install-info install-info-am \ - install-man install-pdf install-pdf-am install-ps \ - install-ps-am install-strip install-toolexeclibLTLIBRARIES \ - installcheck installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags tags-am uninstall uninstall-am \ - uninstall-toolexeclibLTLIBRARIES + install-exec-local install-html install-html-am install-info \ + install-info-am install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-strip \ + install-toolexeclibLTLIBRARIES installcheck installcheck-am \ + installdirs maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \ + uninstall-am uninstall-local uninstall-toolexeclibLTLIBRARIES .PRECIOUS: Makefile +@ENABLE_BACKTRACE_TRUE@install-exec-local: +@ENABLE_BACKTRACE_TRUE@ -cd '$(DESTDIR)$(toolexeclibdir)' && \ +@ENABLE_BACKTRACE_TRUE@ $(LN_S) libstdc++exp.a libstdc++_libbacktrace.a +@ENABLE_BACKTRACE_TRUE@uninstall-local: +@ENABLE_BACKTRACE_TRUE@ -cd '$(DESTDIR)$(toolexeclibdir)' && \ +@ENABLE_BACKTRACE_TRUE@ rm -f libstdc++_libbacktrace.a + # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: diff --git a/libstdc++-v3/src/libbacktrace/Makefile.am b/libstdc++-v3/src/libbacktrace/Makefile.am index 3992f3ab9c5..4a08f11da1e 100644 --- a/libstdc++-v3/src/libbacktrace/Makefile.am +++ b/libstdc++-v3/src/libbacktrace/Makefile.am @@ -31,7 +31,7 @@ include $(top_srcdir)/fragment.am -toolexeclib_LTLIBRARIES = libstdc++_libbacktrace.la +noinst_LTLIBRARIES = libstdc++_libbacktrace.la ACLOCAL_AMFLAGS = -I ../.. -I ../../config diff --git a/libstdc++-v3/src/libbacktrace/Makefile.in b/libstdc++-v3/src/libbacktrace/Makefile.in index f5f19149ae6..6b898f65b06 100644 --- a/libstdc++-v3/src/libbacktrace/Makefile.in +++ b/libstdc++-v3/src/libbacktrace/Makefile.in @@ -150,35 +150,7 @@ DIST_COMMON = $(srcdir)/Makefile.am CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = backtrace-supported.h CONFIG_CLEAN_VPATH_FILES = -am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; -am__vpath_adj = case $$p in \ - $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ - *) f=$$p;; \ - esac; -am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; -am__install_max = 40 -am__nobase_strip_setup = \ - srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` -am__nobase_strip = \ - for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" -am__nobase_list = $(am__nobase_strip_setup); \ - for p in $$list; do echo "$$p $$p"; done | \ - sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ - $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ - if (++n[$$2] == $(am__install_max)) \ - { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ - END { for (dir in files) print dir, files[dir] }' -am__base_list = \ - sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ - sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ - } -am__installdirs = "$(DESTDIR)$(toolexeclibdir)" -LTLIBRARIES = $(toolexeclib_LTLIBRARIES) +LTLIBRARIES = $(noinst_LTLIBRARIES) am_libstdc___libbacktrace_la_OBJECTS = $(obj_prefix)-atomic.lo \ $(obj_prefix)-backtrace.lo $(obj_prefix)-dwarf.lo \ $(obj_prefix)-fileline.lo $(obj_prefix)-posix.lo \ @@ -484,7 +456,7 @@ WARN_CXXFLAGS = \ # -I/-D flags to pass when compiling. AM_CPPFLAGS = $(GLIBCXX_INCLUDES) $(CPPFLAGS) -toolexeclib_LTLIBRARIES = libstdc++_libbacktrace.la +noinst_LTLIBRARIES = libstdc++_libbacktrace.la ACLOCAL_AMFLAGS = -I ../.. -I ../../config # This will be used instead of the common AM_CPPFLAGS from fragment.am @@ -594,33 +566,9 @@ $(am__aclocal_m4_deps): backtrace-supported.h: $(top_builddir)/config.status $(srcdir)/backtrace-supported.h.in cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ -install-toolexeclibLTLIBRARIES: $(toolexeclib_LTLIBRARIES) - @$(NORMAL_INSTALL) - @list='$(toolexeclib_LTLIBRARIES)'; test -n "$(toolexeclibdir)" || list=; \ - list2=; for p in $$list; do \ - if test -f $$p; then \ - list2="$$list2 $$p"; \ - else :; fi; \ - done; \ - test -z "$$list2" || { \ - echo " $(MKDIR_P) '$(DESTDIR)$(toolexeclibdir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(toolexeclibdir)" || exit 1; \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(toolexeclibdir)'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(toolexeclibdir)"; \ - } - -uninstall-toolexeclibLTLIBRARIES: - @$(NORMAL_UNINSTALL) - @list='$(toolexeclib_LTLIBRARIES)'; test -n "$(toolexeclibdir)" || list=; \ - for p in $$list; do \ - $(am__strip_dir) \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(toolexeclibdir)/$$f'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(toolexeclibdir)/$$f"; \ - done - -clean-toolexeclibLTLIBRARIES: - -test -z "$(toolexeclib_LTLIBRARIES)" || rm -f $(toolexeclib_LTLIBRARIES) - @list='$(toolexeclib_LTLIBRARIES)'; \ +clean-noinstLTLIBRARIES: + -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) + @list='$(noinst_LTLIBRARIES)'; \ locs=`for p in $$list; do echo $$p; done | \ sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ sort -u`; \ @@ -630,7 +578,7 @@ clean-toolexeclibLTLIBRARIES: } libstdc++_libbacktrace.la: $(libstdc___libbacktrace_la_OBJECTS) $(libstdc___libbacktrace_la_DEPENDENCIES) $(EXTRA_libstdc___libbacktrace_la_DEPENDENCIES) - $(AM_V_CCLD)$(LINK) -rpath $(toolexeclibdir) $(libstdc___libbacktrace_la_OBJECTS) $(libstdc___libbacktrace_la_LIBADD) $(LIBS) + $(AM_V_CCLD)$(LINK) $(libstdc___libbacktrace_la_OBJECTS) $(libstdc___libbacktrace_la_LIBADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) @@ -756,9 +704,6 @@ check-am: all-am check: check-am all-am: Makefile $(LTLIBRARIES) installdirs: - for dir in "$(DESTDIR)$(toolexeclibdir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done install: install-am install-exec: install-exec-am install-data: install-data-am @@ -791,7 +736,7 @@ maintainer-clean-generic: @echo "it deletes files that may require special tools to rebuild." clean: clean-am -clean-am: clean-generic clean-libtool clean-toolexeclibLTLIBRARIES \ +clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \ mostlyclean-am distclean: distclean-am @@ -817,7 +762,7 @@ install-dvi: install-dvi-am install-dvi-am: -install-exec-am: install-toolexeclibLTLIBRARIES +install-exec-am: install-html: install-html-am @@ -856,24 +801,23 @@ ps: ps-am ps-am: -uninstall-am: uninstall-toolexeclibLTLIBRARIES +uninstall-am: .MAKE: install-am install-strip .PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ - clean-libtool clean-toolexeclibLTLIBRARIES cscopelist-am ctags \ + clean-libtool clean-noinstLTLIBRARIES cscopelist-am ctags \ ctags-am distclean distclean-compile distclean-generic \ distclean-libtool distclean-tags dvi dvi-am html html-am info \ info-am install install-am install-data install-data-am \ install-dvi install-dvi-am install-exec install-exec-am \ install-html install-html-am install-info install-info-am \ install-man install-pdf install-pdf-am install-ps \ - install-ps-am install-strip install-toolexeclibLTLIBRARIES \ - installcheck installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags tags-am uninstall uninstall-am \ - uninstall-toolexeclibLTLIBRARIES + install-ps-am install-strip installcheck installcheck-am \ + installdirs maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \ + uninstall-am .PRECIOUS: Makefile