Commit 0fd76464 authored by Peter Eisentraut's avatar Peter Eisentraut

Make hstore_plperl's build even more like plperl's

Combine the two places that set CPPFLAGS into one.  Also, some settings
should be restricted to Windows only.  More precisely, -Wno-comment is
a GCC-only option, but Windows in a makefile implies GCC at the moment.

Also, since -Wno-comment is more properly a preprocessor option, move it
to CPPFLAGS to simplify things a bit.
parent d664a10f
...@@ -3,7 +3,12 @@ ...@@ -3,7 +3,12 @@
MODULE_big = hstore_plperl MODULE_big = hstore_plperl
OBJS = hstore_plperl.o OBJS = hstore_plperl.o
PG_CPPFLAGS = -I$(top_srcdir)/src/pl/plperl -I$(top_srcdir)/contrib/hstore PG_CPPFLAGS = -I$(top_srcdir)/src/pl/plperl -I$(top_srcdir)/contrib/hstore -I$(perl_archlibexp)/CORE
# see plperl
ifeq ($(PORTNAME), win32)
PG_CPPFLAGS += -DPLPERL_HAVE_UID_GID -Wno-comment
endif
EXTENSION = hstore_plperl hstore_plperlu EXTENSION = hstore_plperl hstore_plperlu
DATA = hstore_plperl--1.0.sql hstore_plperlu--1.0.sql DATA = hstore_plperl--1.0.sql hstore_plperlu--1.0.sql
...@@ -21,6 +26,3 @@ top_builddir = ../.. ...@@ -21,6 +26,3 @@ top_builddir = ../..
include $(top_builddir)/src/Makefile.global include $(top_builddir)/src/Makefile.global
include $(top_srcdir)/contrib/contrib-global.mk include $(top_srcdir)/contrib/contrib-global.mk
endif endif
override CPPFLAGS := $(CPPFLAGS) -I$(perl_archlibexp)/CORE -DPLPERL_HAVE_UID_GID
override CFLAGS += -Wno-comment
...@@ -9,7 +9,7 @@ ifeq ($(PORTNAME), win32) ...@@ -9,7 +9,7 @@ ifeq ($(PORTNAME), win32)
override CPPFLAGS += -DPLPERL_HAVE_UID_GID override CPPFLAGS += -DPLPERL_HAVE_UID_GID
# Perl on win32 contains /* within comment all over the header file, # Perl on win32 contains /* within comment all over the header file,
# so disable this warning. # so disable this warning.
override CFLAGS += -Wno-comment override CPPFLAGS += -Wno-comment
endif endif
override CPPFLAGS := -I. -I$(srcdir) $(CPPFLAGS) -I$(perl_archlibexp)/CORE override CPPFLAGS := -I. -I$(srcdir) $(CPPFLAGS) -I$(perl_archlibexp)/CORE
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment