On Tue, 2006-05-23 at 13:51 +0100, Joe Orton wrote: > > - APR_ADDTO(APRUTIL_INCLUDES, [-I$withval/include/postgresql]) > > + APR_ADDTO(APRUTIL_INCLUDES, [-I/usr/include/postgresql]) > > This also isn't really correct; it presumes that the *only* include path > is /usr/include which isn't necessarily true. The normal way to handle > this is to do directly: > > #ifdef HAVE_LIBPQ_FE_H > #include <libpq_fe.h> > #elif defined(HAVE_POSTGRESQL_LIBPQ_FE_H) > #include <postgresql/libpq-fe.h> > #elendif > > and to ensure that the appropriate HAVE_ symbol gets defined, e.g. by > using AC_CHECK_HEADERS (note plural).
Yeah, all those hard coded things did seem a bit out of place to me too. In the above, I was actually trying to fix the "yes/include/postgresql" problem (i.e. $withval in that part of the code is literally "yes" :-) Again, thanks for reviewing and for the suggestions. I'll work on changing the actual drivers as per above and won't be setting APRUTIL_INCLUDES there at all. -- Bojan
