Since I'm a novice C programmer, this may be a bonehead question, so
please be gentle if the answer is obvious.
I'm creating a shared library of PostgreSQL user functions written in C.
A couple of PG facilities appear very convenient or essential tools for
use in user functions: the palloc function (to allocate PG memory) and
the PG_STR_GET_TEXT and PG_TEXT_GET_STR macros (used to convert between
PG text strings and regular C strings). The problem that arises when I
use these, though, is that they generate unresolved references,
requiring including a seemingly endless chain of dependent PG source
files in the compilation of the library.
Am I way off here, or does using these features massively complicate
compiling and linking my library?
Thanks for any enlightenment?
John Gunther