Re: database session variables
От | Mike Mascari |
---|---|
Тема | Re: database session variables |
Дата | |
Msg-id | 3D9B9426.3000401@mascari.com обсуждение исходный текст |
Ответ на | database session variables ("Mark Wilson" <mark@mediasculpt.com>) |
Список | pgsql-general |
Mark Wilson wrote: > Mike, Thanks heaps for your help here. I'll try that (although I'm a bit of > a freebsd/c newbie). > > My system didn't have postgres.h, so I'm using postgres_fe.h instead. In > addition, I don't have fmgr.h. I downloaded version 1.18 of it from > http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/include/fmgr.h?s > ortby=date&only_with_tag=REL7_2_STABLE, but the first gcc line produced a > number of compiler errors and warnings, starting with: > fmgr.h:30: syntax error before `*' > fmgr.h:30: `Datum' declared as function returning a function > > line 30 of fmgr.h is > typedef Datum (*PGFunction) (FunctionCallInfo fcinfo); > > Do you know what is causing this? (gcc version:gcc-2.95.3) To write server-side C functions you need to be able to include all of the server headers that the C interface requires. When installing PostgreSQL, one normally either does a: ./configure gmake gmake install However, to do server-side development, you also have to do: gmake install-all-headers or, if you are using binary packages you need to install the appropriate package that contains the server-side development headers. For RPMS, the package is: postgresql-devel You should then have all the headers necessary for server-side C development. Hope that helps, Mike Mascari mascarm@mascari.com
В списке pgsql-general по дате отправления: