Re: Should contrib modules install .h files?
Andrew Gierth <andrew@tao11.riddles.org.uk>
From: Andrew Gierth <andrew@tao11.riddles.org.uk>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>,
pgsql-hackers@postgresql.org, Andres Freund <andres@anarazel.de>
Date: 2018-07-02T15:15:56Z
Lists: pgsql-hackers
>>>>> "Tom" == Tom Lane <tgl@sss.pgh.pa.us> writes: Tom> BTW, it's somewhat interesting to think about whether we ought to Tom> change the coding conventions so that extensions refer to their Tom> own headers with a subdirectory, e.g., #include "bloom/bloom.h". Tom> Having done that, all of contrib could build with a single Tom> centrally-provided -I switch pointing at BUILDDIR/contrib/, and Tom> there would be a path to allowing the code to build out of tree by Tom> pointing that common -I at $(includedir_server)/ or Tom> $(includedir_server)/MODULEDIR. This seems like it could be a lot Tom> less messy as we accrete more cross-module references. I'm slightly skeptical of this because it could cause unexpected issues when you rebuild (especially in the PGXS case) a module that has already been installed; without care, you'd end up getting the module's own headers from the installed version rather than the one being built, which would be very bad. -- Andrew (irc:RhodiumToad)
Commits
-
Fix out-of-tree build for transform modules.
- f1ca5a654d5d 11.0 landed
- 60f6756f9225 12.0 landed
-
Provide for contrib and pgxs modules to install include files.
- df163230b92b 12.0 landed
- d06eebce5fa4 11.0 landed