public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] Fix UBSAN bootstrap
@ 2021-01-11 10:26 Martin Liška
  2021-01-11 10:38 ` Jakub Jelinek
  0 siblings, 1 reply; 3+ messages in thread
From: Martin Liška @ 2021-01-11 10:26 UTC (permalink / raw)
  To: gcc-patches; +Cc: Nathan Sidwell, Jakub Jelinek

Hi.

Problem here was that GCC-related options are not applied in stage2 (and later stages).
It's caused by fact that CXX is xg++ in stage2 (and later stages).
Fixed with the following patch.

Ready to be installed?
Thanks,
Martin

libcody/ChangeLog:

	PR bootstrap/98414
	* Makefile.in: In stage2 in UBSAN bootstrap the CXX is called
	xg++, so findstring g++ should be used instead of exact string
	comparison.
---
  libcody/Makefile.in | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libcody/Makefile.in b/libcody/Makefile.in
index 6e38d51516f..1945dc95f14 100644
--- a/libcody/Makefile.in
+++ b/libcody/Makefile.in
@@ -55,7 +55,7 @@ INSTALL := $(srcdir)/build-aux/install-sh
  CXXFLAGS := @CXXFLAGS@
  CXXINC := $(filter -I%,@CXX@)
  CXXOPTS := $(CXXFLAGS) @PICFLAG@
-ifeq ($(notdir $(firstword $(CXX))),g++)
+ifneq (,$(findstring g++, $(notdir $(firstword $(CXX)))))
  # It's GCC, or pretending to be it -- so it better smell like it!
  # Code generation
  CXXOPTS += -fno-enforce-eh-specs
-- 
2.29.2


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-01-11 12:58 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-11 10:26 [PATCH] Fix UBSAN bootstrap Martin Liška
2021-01-11 10:38 ` Jakub Jelinek
2021-01-11 12:58   ` Nathan Sidwell

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).