Re: pgsql: Build all Flex files standalone

From: Andres Freund <andres(at)anarazel(dot)de>
To: John Naylor <john(dot)naylor(at)enterprisedb(dot)com>
Cc: John Naylor <john(dot)naylor(at)postgresql(dot)org>, pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: Re: pgsql: Build all Flex files standalone
Date: 2022-09-04 21:08:12
Message-ID: 20220904210812.icxugcz2syyts3ef@awork3.anarazel.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Hi,

On 2022-09-04 13:19:56 +0700, John Naylor wrote:
> Crake fails with
>
> headerscheck:
> Sep 04 01:56:01 In file included from /tmp/headerscheck.UNgmKy/test.c:2:
> Sep 04 01:56:01
> /home/andrew/bf/root/HEAD/pgsql.build/../pgsql/src/backend/utils/adt/jsonpath_internal.h:26:10:
> fatal error: jsonpath_gram.h: No such file or directory
> Sep 04 01:56:01 26 | #include "jsonpath_gram.h"
> Sep 04 01:56:01 | ^~~~~~~~~~~~~~~~~
> Sep 04 01:56:01 compilation terminated.
> Sep 04 01:56:14 make: *** [GNUmakefile:138: headerscheck] Error 1
> cpluspluscheck:
> Sep 04 01:57:19 In file included from /tmp/cpluspluscheck.HhRV5k/test.cpp:3:
> Sep 04 01:57:19
> /home/andrew/bf/root/HEAD/pgsql.build/../pgsql/src/backend/utils/adt/jsonpath_internal.h:26:10:
> fatal error: jsonpath_gram.h: No such file or directory
> Sep 04 01:57:19 26 | #include "jsonpath_gram.h"
> Sep 04 01:57:19 | ^~~~~~~~~~~~~~~~~
>
> I don't get the same in an already-built tree. I also don't see an
> exception for gramparse.h, which I imagine would have the same issue?

It doesn't happen for gramparse.h because gram.h is copied to
src/include/parser (see src/backend/Makefile), and included as parser/gram.h.

I think this could be addressed by always adding something like
-iquote $builddir/$(dirname "$f") -iquote $srcdir/$(dirname "$f") \
to cpluspluscheck/headerscheck.

Greetings,

Andres Freund

In response to

Browse pgsql-committers by date

  From Date Subject
Next Message Tomas Vondra 2022-09-04 22:08:20 pgsql: Force parallelism in partition_aggregate
Previous Message Andres Freund 2022-09-04 20:57:43 Re: pgsql: Build all Flex files standalone