Skip to content

Commit abeca2e

Browse files
kulaginmgsmolk
authored andcommitted
[PBCKP-232] Remove PG-9.5-9.6 support (postgrespro#523)
* removed support for older versions of postgres (9.5, 9.6) * removed obsolete options (--master-db, --master-host, --master-port, --master-user, --replica-timeout)
1 parent 2e96140 commit abeca2e

31 files changed

+324
-1402
lines changed

Makefile

Lines changed: 6 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -17,21 +17,17 @@
1717
# git clone https://github.com/postgrespro/pg_probackup postgresql/contrib/pg_probackup
1818
# cd postgresql
1919
# ./configure ... && make
20-
# make --no-print-directory -C contrib/pg_probackup
20+
# make -C contrib/pg_probackup
2121
#
2222
# 4. out of PG source and without PGXS
2323
# git clone https://git.postgresql.org/git/postgresql.git postgresql-src
2424
# git clone https://github.com/postgrespro/pg_probackup postgresql-src/contrib/pg_probackup
2525
# mkdir postgresql-build && cd postgresql-build
2626
# ../postgresql-src/configure ... && make
27-
# make --no-print-directory -C contrib/pg_probackup
27+
# make -C contrib/pg_probackup
2828
#
2929
top_pbk_srcdir := $(dir $(realpath $(firstword $(MAKEFILE_LIST))))
3030

31-
# get postgres version
32-
PG_MAJORVER != $(MAKE) USE_PGXS=$(USE_PGXS) PG_CONFIG=$(PG_CONFIG) --silent --makefile=$(top_pbk_srcdir)get_pg_version.mk
33-
#$(info Making with PG_MAJORVER=$(PG_MAJORVER))
34-
3531
PROGRAM := pg_backup
3632

3733
# pg_probackup sources
@@ -46,18 +42,14 @@ OBJS += src/archive.o src/backup.o src/catalog.o src/checkdb.o src/configure.o s
4642
BORROWED_H_SRC := \
4743
src/include/portability/instr_time.h \
4844
src/bin/pg_basebackup/receivelog.h \
49-
src/bin/pg_basebackup/streamutil.h
45+
src/bin/pg_basebackup/streamutil.h \
46+
src/bin/pg_basebackup/walmethods.h
5047
BORROWED_C_SRC := \
5148
src/backend/access/transam/xlogreader.c \
5249
src/backend/utils/hash/pg_crc.c \
5350
src/bin/pg_basebackup/receivelog.c \
54-
src/bin/pg_basebackup/streamutil.c
55-
ifneq ($(PG_MAJORVER), $(findstring $(PG_MAJORVER), 9.5 9.6))
56-
BORROWED_H_SRC += \
57-
src/bin/pg_basebackup/walmethods.h
58-
BORROWED_C_SRC += \
51+
src/bin/pg_basebackup/streamutil.c \
5952
src/bin/pg_basebackup/walmethods.c
60-
endif
6153

6254
BORROW_DIR := src/borrowed
6355
BORROWED_H := $(addprefix $(BORROW_DIR)/, $(notdir $(BORROWED_H_SRC)))
@@ -83,9 +75,6 @@ include $(top_builddir)/src/Makefile.global
8375
include $(top_srcdir)/contrib/contrib-global.mk
8476
endif
8577

86-
# now we can use standard MAJORVERSION variable instead of calculated PG_MAJORVER
87-
undefine PG_MAJORVER
88-
8978
#
9079
PG_CPPFLAGS = -I$(libpq_srcdir) ${PTHREAD_CFLAGS} -I$(top_pbk_srcdir)/src -I$(BORROW_DIR)
9180
ifdef VPATH
@@ -97,11 +86,8 @@ PG_LIBS_INTERNAL = $(libpq_pgport) ${PTHREAD_CFLAGS}
9786
# additional dependencies on borrowed files
9887
src/archive.o: $(BORROW_DIR)/instr_time.h
9988
src/backup.o src/catchup.o src/pg_probackup.o: $(BORROW_DIR)/streamutil.h
100-
src/stream.o $(BORROW_DIR)/receivelog.o $(BORROW_DIR)/streamutil.o: $(BORROW_DIR)/receivelog.h
101-
ifneq ($(MAJORVERSION), $(findstring $(MAJORVERSION), 9.5 9.6))
89+
src/stream.o $(BORROW_DIR)/receivelog.o $(BORROW_DIR)/streamutil.o $(BORROW_DIR)/walmethods.o: $(BORROW_DIR)/receivelog.h
10290
$(BORROW_DIR)/receivelog.h: $(BORROW_DIR)/walmethods.h
103-
$(BORROW_DIR)/walmethods.o: $(BORROW_DIR)/receivelog.h
104-
endif
10591

10692
# generate separate makefile to handle borrowed files
10793
borrowed.mk: $(firstword $(MAKEFILE_LIST))

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
`pg_backup` is a utility to manage backup and recovery of PostgreSQL database clusters. It is designed to perform periodic backups of the PostgreSQL instance that enable you to restore the server in case of a failure.
44

55
The utility is compatible with:
6-
* PostgreSQL 9.6, 10, 11, 12, 13, 14, 15;
6+
* PostgreSQL 10, 11, 12, 13, 14, 15;
77

88
As compared to other backup solutions, `pg_backup` offers the following benefits that can help you implement different backup strategies and deal with large amounts of data:
99
* Incremental backup: page-level incremental backup allows you to save disk space, speed up backup and restore. With three different incremental modes, you can plan the backup strategy in accordance with your data flow.

get_pg_version.mk

Lines changed: 0 additions & 36 deletions
This file was deleted.

0 commit comments

Comments
 (0)