This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [rfa][gold] build debug_msg.o without -fdebug-prefix-map


Chris Demetriou <cgd@google.com> writes:

> in the gold tests, the error messages from linking debug_msg.o are
> checked to verify that the source file names show up correctly in
> error messages.
>
> Use of -fdebug-prefix-map in CXX or CXXFLAGS breaks that test.
>
> To repro, build/test like:
>
> export CC="$GCC_PREFIX/bin/gcc -fdebug-prefix-map=${topdir}=/tmp/foobar"
> export CXX="$GCC_PREFIX//bin/g++ -fdebug-prefix-map=${topdir}=/tmp/foobar"
> CC="${CC}" CXX="${CXX}" "${topdir}/gold/configure" --enable-gold
> make all-gold
> make check-gold
>
> (GCC_PREFIX must contain a version of gcc that supports
> -fdebug-prefix-map, of course.)
>
> the errors you get are like:
>
> Did not find expected error in debug_msg.err:
>    debug_msg.o: in function
> Base::virtfn():/home/cgd/proj/gcctools/sources/gold/gold/testsuite/debug_msg.cc:50:
> error: undefined reference to 'undef_fn1()'


I think we should just change the test.  The test (in
gold/testsuite/debug_msg.sh) is trying to match ${srcdir} precisely.
That's not relevant to what is being tested here; it suffices to match
debug_msg.cc.  So let's just s/${srcdir}/.*/ in debug_msg.sh.  If that
works, the patch is preapproved.

Thanks.

Ian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]