CC = @CC@
CFLAGS = @CFLAGS@
DEFS = @DEFS@
-INCLUDES = -I$(srcdir) -I$(top_srcdir) @CPPFLAGS@
+# add include dir .. for config.h when building in different directory
+INCLUDES = -I$(srcdir) -I$(top_srcdir) -I.. @CPPFLAGS@
LDFLAGS = @LDFLAGS@
LIBS = @LIBS@