--- postgresql-14.0.orig/src/bin/pg_config/pg_config.c 2021-11-01 14:48:22.654149731 +0100
+++ postgresql-14.0/src/bin/pg_config/pg_config.c 2021-11-01 14:49:14.747282545 +0100
@@ -27,6 +27,8 @@
+
#include "common/config_info.h"
- #include "port.h"
+#include "../port/pg_config_paths.h"
+
+++ postgresql-16.1/configure.ac 2023-12-13 21:54:44.023989230 +0100
@@ -19,10 +19,6 @@
- AC_INIT([PostgreSQL], [17.7], [pgsql-bugs@lists.postgresql.org], [], [https://www.postgresql.org/])
+ AC_INIT([PostgreSQL], [18.1], [pgsql-bugs@lists.postgresql.org], [], [https://www.postgresql.org/])
-m4_if(m4_defn([m4_PACKAGE_VERSION]), [2.69], [], [m4_fatal([Autoconf version 2.69 is required.
-Untested combinations of 'autoconf' and PostgreSQL versions are not
-recommended. You can remove the check from 'configure.ac' but it is then
-your responsibility whether the result works or not.])])
- AC_COPYRIGHT([Copyright (c) 1996-2024, PostgreSQL Global Development Group])
+ AC_COPYRIGHT([Copyright (c) 1996-2025, PostgreSQL Global Development Group])
AC_CONFIG_SRCDIR([src/backend/access/common/heaptuple.c])
AC_CONFIG_AUX_DIR(config)
---- postgresql-17.5/src/backend/utils/misc/postgresql.conf.sample 2025-05-05 22:28:35.000000000 +0200
-+++ postgresql-17.5/src/backend/utils/misc/postgresql.conf.sample 2025-08-12 14:03:04.615779844 +0200
-@@ -466,28 +466,28 @@
+--- postgresql-18.1/src/backend/utils/misc/postgresql.conf.sample 2025-11-10 22:52:06.000000000 +0100
++++ postgresql-18.1/src/backend/utils/misc/postgresql.conf.sample 2025-12-13 17:28:04.314306530 +0100
+@@ -481,28 +481,28 @@
# - Where to Log -
-#log_filename = 'postgresql-%Y-%m-%d_%H%M%S.log' # log file name pattern,
- # can include strftime() escapes
-#log_file_mode = 0600 # creation mode for log files,
-+log_filename = 'postgresql-16.log' # log file name pattern,
++log_filename = 'postgresql-18.log' # log file name pattern,
+ # can include strftime() escapes
+log_file_mode = 0640 # creation mode for log files,
# begin with 0 to use octal notation
# happen after that much log output.
# 0 disables.
#log_truncate_on_rotation = off # If on, an existing log file with the
-@@ -500,9 +500,9 @@
+@@ -515,9 +515,9 @@
# in all cases.
# These are relevant when logging to syslog:
#syslog_split_messages = on
# This is only relevant when logging to eventlog (Windows):
-@@ -576,12 +576,12 @@
+@@ -591,14 +591,14 @@
# actions running at least this number
# of milliseconds.
#log_checkpoints = on
--#log_connections = off
+-#log_connections = '' # log aspects of connection setup
++log_connections = 'all' # log aspects of connection setup
+ # options include receipt, authentication, authorization,
+ # setup_durations, and all to log all of these aspects
-#log_disconnections = off
-+log_connections = on
+log_disconnections = on
- #log_duration = off
+ #log_duration = off # log statement duration
#log_error_verbosity = default # terse, default, or verbose messages
#log_hostname = off
-#log_line_prefix = '%m [%p] ' # special values:
-+#log_line_prefix = '%m [%p] %q%h/%a %u/%d ' # special values:
++#log_line_prefix = '%m [%p] %q%h/%a %u/%d ' # special values:
# %a = application name
# %u = user name
# %d = database name
#
%define beta %{nil}
-%define pgsqlversion 17
-%define pgsqlpriority 170
+%define pgsqlversion 18
+%define pgsqlpriority 180
Summary: PostgreSQL Data Base Management System
Summary(de.UTF-8): PostgreSQL Datenbankverwaltungssystem
Summary(uk.UTF-8): PostgreSQL - система керування базами даних
Summary(zh_CN.UTF-8): PostgreSQL 客户端程序和库文件
Name: postgresql-%{pgsqlversion}
-Version: %{pgsqlversion}.7
+Version: %{pgsqlversion}.1
Release: 1
License: BSD
Group: Applications/Databases
Source0: http://ftp.postgresql.org/pub/source/v%{version}/postgresql-%{version}.tar.bz2
-# Source0-md5: a4fa04d16e511e068736d154ca74752d
+# Source0-md5: 32f047dc587bbc90a4f68ea7b903485d
Source1: postgresql.init
Source2: pgsql-Database-HOWTO-html.tar.gz
# Source2-md5: 5b656ddf1db41965761f85204a14398e
# omitted contribs:
# spi, test_decoding, worker_spi - examples/tests
# tsearch2 - old module for compatibility only
-%define contrib_modules amcheck auth_delay auto_explain basebackup_to_shell basic_archive bloom %{?with_perl:bool_plperl} btree_gin btree_gist citext cube dblink dict_int dict_xsyn earthdistance file_fdw fuzzystrmatch hstore %{?with_perl:hstore_plperl} %{?with_python:hstore_plpython} intagg intarray isn %{?with_perl:jsonb_plperl} %{?with_python:jsonb_plpython} lo ltree %{?with_python:ltree_plpython} oid2name pageinspect passwordcheck pg_buffercache pg_freespacemap pg_prewarm pg_stat_statements pg_surgery pg_trgm pg_visibility pg_walinspect pgcrypto pgrowlocks pgstattuple postgres_fdw seg %{?with_selinux:sepgsql} spi sslinfo tablefunc tcn tsm_system_rows tsm_system_time unaccent uuid-ossp vacuumlo xml2
+%define contrib_modules amcheck auth_delay auto_explain basebackup_to_shell basic_archive bloom %{?with_perl:bool_plperl} btree_gin btree_gist citext cube dblink dict_int dict_xsyn earthdistance file_fdw fuzzystrmatch hstore %{?with_perl:hstore_plperl} %{?with_python:hstore_plpython} intagg intarray isn %{?with_perl:jsonb_plperl} %{?with_python:jsonb_plpython} lo ltree %{?with_python:ltree_plpython} oid2name pageinspect passwordcheck pg_buffercache pg_freespacemap pg_logicalinspect pg_overexplain pg_prewarm pg_stat_statements pg_surgery pg_trgm pg_visibility pg_walinspect pgcrypto pgrowlocks pgstattuple postgres_fdw seg %{?with_selinux:sepgsql} spi sslinfo tablefunc tcn tsm_system_rows tsm_system_time unaccent uuid-ossp vacuumlo xml2
%description
PostgreSQL Data Base Management System (formerly known as Postgres,
%{_includedir}/libpq-events.h
%{_includedir}/libpq-fe.h
%{_includedir}/pg_config.h
-%{_includedir}/pg_config_ext.h
+#%%{_includedir}/pg_config_ext.h
%{_includedir}/pg_config_manual.h
%{_includedir}/pg_config_os.h
%{_includedir}/postgres_ext.h
%attr(755,root,root) %{moduledir}/passwordcheck.so
%attr(755,root,root) %{moduledir}/pg_buffercache.so
%attr(755,root,root) %{moduledir}/pg_freespacemap.so
+%attr(755,root,root) %{moduledir}/pg_logicalinspect.so
+%attr(755,root,root) %{moduledir}/pg_overexplain.so
%attr(755,root,root) %{moduledir}/pg_prewarm.so
%attr(755,root,root) %{moduledir}/pg_stat_statements.so
%attr(755,root,root) %{moduledir}/pg_surgery.so
%{extensiondir}/pg_buffercache.control
%{extensiondir}/pg_freespacemap--*.sql
%{extensiondir}/pg_freespacemap.control
+%{extensiondir}/pg_logicalinspect--*.sql
+%{extensiondir}/pg_logicalinspect.control
%{extensiondir}/pg_prewarm--*.sql
%{extensiondir}/pg_prewarm.control
%{extensiondir}/pg_stat_statements--*.sql
--- postgresql-16.1.orig/src/bin/pg_upgrade/option.c 2023-11-06 23:04:27.000000000 +0100
+++ postgresql-16.1/src/bin/pg_upgrade/option.c 2023-12-13 21:51:21.445407619 +0100
@@ -456,8 +456,14 @@
- get_sock_dir(ClusterInfo *cluster, bool live_check)
+ get_sock_dir(ClusterInfo *cluster)
{
#if !defined(WIN32)
-- if (!live_check)
-+ if (!live_check) {
+- if (!user_opts.live_check || cluster == &new_cluster)
++ if (!user_opts.live_check || cluster == &new_cluster) {
cluster->sockdir = user_opts.socketdir;
+#ifndef UNIX_PATH_MAX
+#define UNIX_PATH_MAX 108