I said:
> I have to take that back: the bison outputs are rebuilt in the source
> tree, as indeed they should be. I'm now fairly confused about why
> the first build attempt failed and the second succeeded.
The difference appears to be that when bison is run in the source dir,
its output contains lines like
#line 121 "bootscanner.l"
However, when it's run during a VPATH build, its output contains lines
like
#line 121 "/home/postgres/pgsql/src/backend/bootstrap/bootscanner.l"
evidently because bison is invoked with a full path to the .y file in
this case.
There is *no* difference in the #include commands, but apparently the
#line directives affect gcc's default search path for include files.
Net result: I'm back to my original statement: VPATH builds will not
work with a source distribution tarball. Any objections to the
-I$(srcdir) trick?
regards, tom lane