When building with --with-pgport slonik needs to include port.h
port.h is normally found under the server include directory but
some distributions (ie debian libpq-dev) also include it in
/usr/include/postgresql
The fix for bug 315 removed the server include paths from
all client programs including slonik. This went too far,
the actual issue with bug 315 was src/backend failing because
it pulled in the client headers.
If we are building with pgport we will pull in the server
include directories for slonik
slony_top_builddir = ../..
SLFILEDESC="Slony command interpreter"
include $(slony_top_builddir)/Makefile.global
+ifeq ($(HAVE_PGPORT),1)
+CPPFLAGS:=$(CPPFLAGS_SERVER) $(CPPFLAGS_CLIENT)
+else
CPPFLAGS:=$(CPPFLAGS_CLIENT)
-
+endif
ifeq ($(PORTNAME), aix)
CFLAGS += -D_LARGE_FILES
endif