Re: Should contrib modules install .h files? - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Should contrib modules install .h files?
Date
Msg-id 63655.1530540982@sss.pgh.pa.us
Whole thread Raw
In response to Re: Should contrib modules install .h files?  (Andrew Gierth <andrew@tao11.riddles.org.uk>)
Responses Re: Should contrib modules install .h files?  (Andrew Gierth <andrew@tao11.riddles.org.uk>)
List pgsql-hackers
Andrew Gierth <andrew@tao11.riddles.org.uk> writes:
> "Tom" == Tom Lane <tgl@sss.pgh.pa.us> writes:
>  Tom> FWIW, I agree with Andres' thought that each contrib module should
>  Tom> have its own subdirectory under $(includedir_server). Otherwise
>  Tom> we're going to be faced with questions about whether .h files need
>  Tom> to be renamed because they're not globally unique enough. There
>  Tom> are already some that are pretty shaky from this standpoint:

> I'm not suggesting that all modules should install a .h file or that all
> of a module's .h files should be installed.

I agree with that, which implies the need for a new macro comparable to
DATA and DOCS that lists the .h files to be installed.

> A slight snag in trying to use a subdir for each module is that there is
> not in fact anywhere in the existing makefiles that uses or assigns such
> a name. Indeed some contrib subdirs install multiple modules.

So, given that we have to add something to the module makefiles anyway,
we could also add a macro specifying the subdirectory name to use.
(Although in practice this should always be equal to the contrib/
subdirectory name, so maybe we could extract it on that basis?)

            regards, tom lane


pgsql-hackers by date:

Previous
From: Andrew Gierth
Date:
Subject: Re: Should contrib modules install .h files?
Next
From: "Andrey V. Lepikhov"
Date:
Subject: Re: [WIP] [B-Tree] Retail IndexTuple deletion