@@ -13,11 +13,11 @@ OBJS += src/archive.o src/backup.o src/catalog.o src/checkdb.o src/configure.o s
1313OBJS += src/pg_crc.o src/datapagemap.o src/receivelog.o src/streamutil.o \
1414 src/xlogreader.o
1515
16- EXTRA_CLEAN = src/pg_crc.c src/datapagemap.c src/datapagemap.h src/logging.h \
16+ EXTRA_CLEAN = src/pg_crc.c src/datapagemap.c src/datapagemap.h \
1717 src/receivelog.c src/receivelog.h src/streamutil.c src/streamutil.h \
1818 src/xlogreader.c
1919
20- INCLUDES = src/datapagemap.h src/logging.h src/ streamutil.h src/receivelog.h
20+ INCLUDES = src/datapagemap.h src/streamutil.h src/receivelog.h
2121
2222ifdef USE_PGXS
2323PG_CONFIG = pg_config
3939srchome =$(top_srcdir )
4040endif
4141
42+ ifneq (12,$(MAJORVERSION ) )
43+ EXTRA_CLEAN += src/logging.h
44+ INCLUDES += src/logging.h
45+ endif
46+
4247ifeq (,$(filter 9.5 9.6,$(MAJORVERSION ) ) )
4348OBJS += src/walmethods.o
4449EXTRA_CLEAN += src/walmethods.c src/walmethods.h
4550INCLUDES += src/walmethods.h
4651endif
4752
53+
4854PG_CPPFLAGS = -I$(libpq_srcdir ) ${PTHREAD_CFLAGS} -Isrc -I$(top_srcdir ) /$(subdir ) /src
4955override CPPFLAGS := -DFRONTEND $(CPPFLAGS ) $(PG_CPPFLAGS )
5056PG_LIBS_INTERNAL = $(libpq_pgport ) ${PTHREAD_CFLAGS}
@@ -70,10 +76,7 @@ src/streamutil.h: $(top_srcdir)/src/bin/pg_basebackup/streamutil.h
7076src/xlogreader.c : $(top_srcdir ) /src/backend/access/transam/xlogreader.c
7177 rm -f $@ && $(LN_S ) $(srchome ) /src/backend/access/transam/xlogreader.c $@
7278
73- ifeq (12,$(MAJORVERSION ) )
74- src/logging.h : $(top_srcdir ) /src/include/common/logging.h
75- rm -f $@ && $(LN_S ) $(srchome ) /src/include/common/logging.h $@
76- else
79+ ifneq (12,$(MAJORVERSION ) )
7780src/logging.h : $(top_srcdir ) /src/bin/pg_rewind/logging.h
7881 rm -f $@ && $(LN_S ) $(srchome ) /src/bin/pg_rewind/logging.h $@
7982endif
0 commit comments