7a3996
We should ideally provide '/bin/pg_config' in postgresql-server-devel, and
7a3996
provide no pg_config binary in libpq package.  But most of the Fedora packages
7a3996
that use pg_config actually only build against PG libraries (and
7a3996
postgresql-server-devel isn't needed).  So.., to avoid the initial rush around
7a3996
rhbz#1618698 change, rather provide pg_server_config binary, which int urn means
7a3996
that we'll have to fix only a minimal set of packages which really build
7a3996
PostgreSQL server modules.
7a3996
7a3996
diff -up postgresql-13.1/src/bin/pg_config/Makefile.patch9 postgresql-13.1/src/bin/pg_config/Makefile
7a3996
--- postgresql-13.1/src/bin/pg_config/Makefile.patch9	2020-11-18 09:28:30.885453275 +0100
7a3996
+++ postgresql-13.1/src/bin/pg_config/Makefile	2020-11-18 09:31:33.926325327 +0100
7a3996
@@ -11,6 +11,8 @@
7a3996
 PGFILEDESC = "pg_config - report configuration information"
7a3996
 PGAPPICON=win32
7a3996
 
7a3996
+PG_CONFIG = pg_server_config$(X)
7a3996
+
7a3996
 subdir = src/bin/pg_config
7a3996
 top_builddir = ../../..
7a3996
 include $(top_builddir)/src/Makefile.global
7a3996
@@ -19,22 +21,22 @@ OBJS = \
7a3996
 	$(WIN32RES) \
7a3996
 	pg_config.o
7a3996
 
7a3996
-all: pg_config
7a3996
+all: $(PG_CONFIG)
7a3996
 
7a3996
-pg_config: $(OBJS) | submake-libpgport
7a3996
-	$(CC) $(CFLAGS) $(OBJS) $(LDFLAGS) $(LDFLAGS_EX) $(LIBS) -o $@$(X)
7a3996
+$(PG_CONFIG): $(OBJS) | submake-libpgport
7a3996
+	$(CC) $(CFLAGS) $(OBJS) $(LDFLAGS) $(LDFLAGS_EX) $(LIBS) -o $@
7a3996
 
7a3996
 install: all installdirs
7a3996
-	$(INSTALL_SCRIPT) pg_config$(X) '$(DESTDIR)$(bindir)/pg_config$(X)'
7a3996
+	$(INSTALL_SCRIPT) $(PG_CONFIG) '$(DESTDIR)$(bindir)/$(PG_CONFIG)'
7a3996
 
7a3996
 installdirs:
7a3996
 	$(MKDIR_P) '$(DESTDIR)$(bindir)'
7a3996
 
7a3996
 uninstall:
7a3996
-	rm -f '$(DESTDIR)$(bindir)/pg_config$(X)'
7a3996
+	rm -f '$(DESTDIR)$(bindir)/$(PG_CONFIG)'
7a3996
 
7a3996
 clean distclean maintainer-clean:
7a3996
-	rm -f pg_config$(X) $(OBJS)
7a3996
+	rm -f $(PG_CONFIG) $(OBJS)
7a3996
 	rm -rf tmp_check
7a3996
 
7a3996
 check:
7a3996
diff -up postgresql-13.1/src/bin/pg_config/nls.mk.patch9 postgresql-13.1/src/bin/pg_config/nls.mk
7a3996
--- postgresql-13.1/src/bin/pg_config/nls.mk.patch9	2020-11-18 09:28:30.885453275 +0100
7a3996
+++ postgresql-13.1/src/bin/pg_config/nls.mk	2020-11-18 09:32:00.735599526 +0100
7a3996
@@ -1,4 +1,4 @@
7a3996
 # src/bin/pg_config/nls.mk
7a3996
-CATALOG_NAME     = pg_config
7a3996
+CATALOG_NAME     = pg_server_config
7a3996
 AVAIL_LANGUAGES  = cs de el es fr he it ja ka ko pl pt_BR ru sv tr uk vi zh_CN
7a3996
 GETTEXT_FILES    = pg_config.c ../../common/config_info.c ../../common/exec.c