public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "hjl.tools at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug sanitizer/55533] New: Can't bootstrap libsanitizer
Date: Thu, 29 Nov 2012 20:19:00 -0000 [thread overview]
Message-ID: <bug-55533-4@http.gcc.gnu.org/bugzilla/> (raw)
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55533
Bug #: 55533
Summary: Can't bootstrap libsanitizer
Classification: Unclassified
Product: gcc
Version: 4.8.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: sanitizer
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: hjl.tools@gmail.com
CC: dodji@gcc.gnu.org, dvyukov@gcc.gnu.org,
jakub@gcc.gnu.org, kcc@gcc.gnu.org
Created attachment 28830
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28830
A patch to boostrap libsanitizer
When bootstrap libsanitizer with
target_modules = { module= libsanitizer;
bootstrap=true;
lib_path=.libs; };
on Linux/ia32 and Linux/x86-64, I got
/bin/sh ../libtool --tag=CXX --mode=compile
/export/build/gnu/gcc/build-x86_64-linux/./gcc/xg++
-B/export/build/gnu/gcc/build-x86_64-linux/./gcc/ -nostdinc++
-funconfigured-libstdc++-v3
-L/export/build/gnu/gcc/build-x86_64-linux/x86_64-unknown-linux-gnu/libstdc++-v3/src
-L/export/build/gnu/gcc/build-x86_64-linux/x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs
-B/usr/gcc-4.8.0/x86_64-unknown-linux-gnu/bin/
-B/usr/gcc-4.8.0/x86_64-unknown-linux-gnu/lib/ -isystem
/usr/gcc-4.8.0/x86_64-unknown-linux-gnu/include -isystem
/usr/gcc-4.8.0/x86_64-unknown-linux-gnu/sys-include -D_GNU_SOURCE -D_DEBUG
-D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I.
-I/export/gnu/import/git/gcc/libsanitizer/interception -I
/export/gnu/import/git/gcc/libsanitizer/include -Wall -W
-Wno-unused-parameter -Wwrite-strings -pedantic -Wno-long-long -fPIC
-fno-builtin -fno-exceptions -fomit-frame-pointer -funwind-tables
-fvisibility=hidden -Wno-variadic-macros -Wno-c99-extensions -g -O2
-D_GNU_SOURCE -c -o interception_linux.lo
/export/gnu/import/git/gcc/libsanitizer/interception/interception_linux.cc
xg++: error: unrecognized command line option ‘-funconfigured-libstdc++-v3’
make[5]: *** [interception_linux.lo] Error 1
make[5]: *** Waiting for unfinished jobs....
From Makefile.tpl:
# CXX_FOR_TARGET is tricky to get right for target libs that require a
# functional C++ compiler. When we recurse, if we expand
# CXX_FOR_TARGET before configuring libstdc++-v3, we won't get
# libstdc++ include flags from the script. Instead, we get an
# -funconfigured-* word, so that we'll get errors if this invalid C++
# command line is used for anything, but also so that we can use the
# word to decide whether or not to pass on this CXX_FOR_TARGET. If we
# don't pass it on, sub-make will use the default definition, that
# re-expands it at the time of use, so we'll get it right when we need
# it. One potential exception is the expansion of CXX_FOR_TARGET
# passed down as part of CXX within TARGET_FLAGS, but this wouldn't
# really work, for C++ host programs can't depend on the current-stage
# C++ target library.
CXX_FOR_TARGET_FLAG_TO_PASS = \
$(shell if echo "$(CXX_FOR_TARGET)" | grep " -funconfigured-"
> /dev/null; then :; else echo '"CXX_FOR_TARGET=$(CXX_FOR_TARGET)"';
fi)
When we expand CXX_FOR_TARGET for libsanitizer before configuring it,
libstdc++-v3/scripts/testsuite_flags isn't available yet. The solution
is to set raw_cxx=true and use -I to include libstdc++ header file
explicitly when the C++ library is used for bootstrap.
next reply other threads:[~2012-11-29 20:19 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-29 20:19 hjl.tools at gmail dot com [this message]
2012-11-29 20:22 ` [Bug sanitizer/55533] " hjl.tools at gmail dot com
2012-12-11 21:32 ` hjl at gcc dot gnu.org
2012-12-11 23:40 ` hjl.tools at gmail dot com
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=bug-55533-4@http.gcc.gnu.org/bugzilla/ \
--to=gcc-bugzilla@gcc.gnu.org \
--cc=gcc-bugs@gcc.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).