Re: autogenerating error code lists (was Re: [COMMITTERS] pgsql: Add foreign data wrapper error code values for SQL/MED.)

Поиск
Список
Период
Сортировка
От Jan Urbański
Тема Re: autogenerating error code lists (was Re: [COMMITTERS] pgsql: Add foreign data wrapper error code values for SQL/MED.)
Дата
Msg-id 4D2C954B.8050500@wulczer.org
обсуждение исходный текст
Ответ на Re: autogenerating error code lists (was Re: [COMMITTERS] pgsql: Add foreign data wrapper error code values for SQL/MED.)  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: autogenerating error code lists (was Re: [COMMITTERS] pgsql: Add foreign data wrapper error code values for SQL/MED.)  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On 11/01/11 17:11, Tom Lane wrote:
> Jan Urbański <wulczer@wulczer.org> writes:
>>> I tried wiring it into the build system, but failed, I can't figure out
>>> which Makefiles should be updated in order to make errcodes.h and
>>> plerrcodes.h generated headers. Could someone help with that?
> 
>> Trying a bit harder to make src/include/utils/errcodes.h a generated
>> file I found that it's included so early it makes the task not trivial
>> at all. postgres.h includes elog.h, which includes errcodes.h (after
>> defining the MAKE_SQLSTATE macro). I'm not sure how to proceed:
> 
> Huh?  Why in the world would the specific location of the #include have
> anything to do with the problem?

I'v having a hard time convincing make to generate errcodes.h before
compiling any .c file that includes postgres.h. The only way I found was
to make src/include/errcodes.h a dependancy of the all target.

For instance, I tried to copy the way we generate fmgroids.h and it
turned out that it doesn't work (it tries to compile things in src/port
before entering src/include, and things in src/port include postgres.h).


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Jeff Davis
Дата:
Сообщение: Re: SSI and 2PC
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Streaming base backups