public inbox for libstdc++@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] PR libstdc++/85442 fix duplicate debuginfo for cxx11-ios_failure.cc
@ 2018-04-18 12:15 Jonathan Wakely
  0 siblings, 0 replies; only message in thread
From: Jonathan Wakely @ 2018-04-18 12:15 UTC (permalink / raw)
  To: libstdc++, gcc-patches

[-- Attachment #1: Type: text/plain, Size: 767 bytes --]

The fix for PR 85222 ends up generating duplicate debuginfo sections,
because we compile the .cc file and then compile the .s file. This
adds -g0 to the second step so we don't generate debuginfo again.

I've verified that we still have debuginfo for the file and can step
through the code when using the $prefix/lib64/debug/libstdc++.so.6
version of the library.

2018-04-18  Jonathan Wakely  <jwakely@redhat.com>
                Jakub Jelinek  <jakub@redhat.com>

            PR libstdc++/85442
            * src/c++11/Makefile.am: Don't generate debuginfo again for
            cxx11-ios_failure-lt.s and cxx11-ios_failure.s files.
            * src/c++11/Makefile.in: Regenerate.

Tested powerpc64le-linux, committed to trunk. Backport to gcc-7-branch
to follow.

[-- Attachment #2: patch.txt --]
[-- Type: text/plain, Size: 1098 bytes --]

commit 55c94164faf1f124b5c88067ead6871f383fb319
Author: Jonathan Wakely <jwakely@redhat.com>
Date:   Wed Apr 18 12:27:11 2018 +0100

    PR libstdc++/85442 fix duplicate debuginfo for cxx11-ios_failure.cc
    
    2018-04-18  Jonathan Wakely  <jwakely@redhat.com>
                Jakub Jelinek  <jakub@redhat.com>
    
            PR libstdc++/85442
            * src/c++11/Makefile.am: Don't generate debuginfo again for
            cxx11-ios_failure-lt.s and cxx11-ios_failure.s files.
            * src/c++11/Makefile.in: Regenerate.

diff --git a/libstdc++-v3/src/c++11/Makefile.am b/libstdc++-v3/src/c++11/Makefile.am
index cdc49bb7f9b..91bf6f8d642 100644
--- a/libstdc++-v3/src/c++11/Makefile.am
+++ b/libstdc++-v3/src/c++11/Makefile.am
@@ -141,9 +141,9 @@ cxx11-ios_failure.s: cxx11-ios_failure.cc
 	-rm -f tmp-$@
 
 cxx11-ios_failure.lo: cxx11-ios_failure-lt.s
-	$(LTCXXCOMPILE) -c $< -o $@
+	$(LTCXXCOMPILE) -g0 -c $< -o $@
 cxx11-ios_failure.o: cxx11-ios_failure.s
-	$(CXXCOMPILE) -c $<
+	$(CXXCOMPILE) -g0 -c $<
 endif
 
 # AM_CXXFLAGS needs to be in each subdirectory so that it can be

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2018-04-18 12:15 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-04-18 12:15 [PATCH] PR libstdc++/85442 fix duplicate debuginfo for cxx11-ios_failure.cc Jonathan Wakely

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).