[head] Java bootstrap failure: natClip.cc:26: syntax error before`;'
Alexandre Oliva
aoliva@redhat.com
Fri Feb 23 21:11:00 GMT 2001
On Feb 17, 2001, "Zack Weinberg" <zackw@stanford.edu> wrote:
> On Sat, Feb 17, 2001 at 10:40:43AM +0100, Gerald Pfeifer wrote:
>> On Sat, 17 Feb 2001, Bryce McKinlay wrote:
>> > So, the problem is that the appropriate libstdc++ -I flags (the
>> > contents of $builddir/libstdc++-v3/src/libstdc++.INC) arn't getting
>> > included in what the toplevel passes down to libjava's make in the CXX
>> > variable.
>> > This seems to crop up occasionally, but I dont really know what causes
>> > it. "rm -rf" your build directory and starting again ought to fix it
>> > ;-)
>>
>> No, I'm using a fresh build directory for every build :-) (and I got this
>> failure three times yesterday before reporting it).
> I get this too. It's classic incomprehensible shell/Make behavior.
> In the top level configure.in, there is this lovely bit of gibberish:
:-)
> # Don't use libstdc++-v3's flags to configure/build itself.
> libstdcxx_flags='`case $$dir in libstdc++-v3) ;; *) cat $$r/$(TARGET_SUBDIR)/libstdc++-v3/src/libstdc++.INC 2>/dev/null || : ;; esac` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs'
> Yep, all one long line. This gets stuffed into the definition of
> CXX_FOR_TARGET in the top level Makefile. When we go to build
> libjava, it does export CXX="$(CXX_FOR_TARGET)" first.
> If I replace the backquoted expression with
> `cat $$r/$(TARGET_SUBDIR)/libstdc++-v3/src/libstdc++.INC`
> then libjava completes its build successfully. So the problem is not
> with finding libstdc++.INC, or its contents. And $$dir is libjava, so
> the cat should get executed - but it doesn't. I stuck debugging echos
> all over that thing and it appears that neither branch of the case
> gets executed. I don't know how that could happen, but it is.
The only substantial difference I can find between
CONFIGURE_TARGET_MODULES, that works, and ALL_TARGET_MODULES, that
doesn't, is that CXX is evaluated in a shell assignment and exported
in `configure', but used only as an argument to make in `all'.
I suppose this might make a difference in case make processes
command-line arguments in a different way. For one, we'd pass
CXX_FOR_TARGET in BASE_FLAGS_TO_PASS, with the value we want, and then
pass CXX='$$(CXX_FOR_TARGET)' in EXTRA_TARGET_FLAGS. I'm not sure
this is always evaluated correctly, or that it means what we want it
to mean. It might be that make takes CXX_FOR_TARGET from the
environment, instead of from the command-line, of something crazy like
that. In this case, `dir' wouldn't be available for the test, since,
unlike r and s, it's not exported.
Unfortunately, I couldn't duplicate this behavior with GNU make
3.79.1. Which `make' are you folks using? When you run:
% make MAKE=/path/to/make-verbose.sh
where make-verbose.sh is:
#! /bin/sh
echo cd `pwd` "&&" make ${1+"$@"}
echo CXX_FOR_TARGET=$CXX_FOR_TARGET
exec make MAKE=make ${1+"$@"}
what do you get in CXX_FOR_TARGET when entering the libjava directory,
both in the `make' argument-list and in the environment?
--
Alexandre Oliva Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicamp oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist *Please* write to mailing lists, not to me
More information about the Gcc-bugs
mailing list