]> git.ipfire.org Git - thirdparty/postgresql.git/commitdiff
Ensure that all three build methods install the same set of files.
authorTom Lane <tgl@sss.pgh.pa.us>
Mon, 16 Feb 2026 20:20:15 +0000 (15:20 -0500)
committerTom Lane <tgl@sss.pgh.pa.us>
Mon, 16 Feb 2026 20:20:15 +0000 (15:20 -0500)
syscache_info.h was installed into $installdir/include/server/catalog
if you use a non-VPATH autoconf build, but not if you use a VPATH
build or meson.  That happened because the makefiles blindly install
src/include/catalog/*.h, and in a non-VPATH build the generated
header files would be swept up in that.  While it's hard to conjure
a reason to need syscache_info.h outside of backend build, it's
also hard to get the makefiles to skip syscache_info.h, so let's
go the other way and install it in the other two cases too.

Another problem, new in v19, was that meson builds install a copy of
src/include/catalog/README, while autoconf builds do not.  The issue
here is that that file is new and wasn't added to meson.build's
exclusion list.

While it's clearly a bug if different build methods don't install
the same set of files, I doubt anyone would thank us for changing
the behavior in released branches.  Hence, fix in master only.

Author: Tom Lane <tgl@sss.pgh.pa.us>
Reviewed-by: Andres Freund <andres@anarazel.de>
Discussion: https://postgr.es/m/946828.1771185367@sss.pgh.pa.us

src/include/catalog/Makefile
src/include/catalog/meson.build
src/include/meson.build

index c90022f7c57ccdd792b0d7c6e19ddf0c3306d0de..24b527230d47640964432655ac3255fe0a9111b7 100644 (file)
@@ -149,6 +149,7 @@ install: all installdirs
 ifeq ($(vpath_build),yes)
        $(INSTALL_DATA) schemapg.h '$(DESTDIR)$(includedir_server)'/catalog/schemapg.h
        $(INSTALL_DATA) syscache_ids.h '$(DESTDIR)$(includedir_server)'/catalog/syscache_ids.h
+       $(INSTALL_DATA) syscache_info.h '$(DESTDIR)$(includedir_server)'/catalog/syscache_info.h
        $(INSTALL_DATA) system_fk_info.h '$(DESTDIR)$(includedir_server)'/catalog/system_fk_info.h
        for file in $(GENERATED_HEADERS); do \
          $(INSTALL_DATA) $$file '$(DESTDIR)$(includedir_server)'/catalog/$$file || exit; \
@@ -160,7 +161,7 @@ installdirs:
 
 uninstall:
        rm -f $(addprefix '$(DESTDIR)$(datadir)'/, postgres.bki system_constraints.sql)
-       rm -f $(addprefix '$(DESTDIR)$(includedir_server)'/catalog/, schemapg.h syscache_ids.h system_fk_info.h $(GENERATED_HEADERS))
+       rm -f $(addprefix '$(DESTDIR)$(includedir_server)'/catalog/, schemapg.h syscache_ids.h syscache_info.h system_fk_info.h $(GENERATED_HEADERS))
 
 clean:
        rm -f bki-stamp $(GENBKI_OUTPUT_FILES)
index b63cd58406894ce83d43cdc39af59d011e12ac1f..433bcc908ad1c6dc0437963666f73756e98da7fa 100644 (file)
@@ -115,7 +115,7 @@ output_install = [
   dir_data,
   dir_include_server / 'catalog',
   dir_include_server / 'catalog',
-  false,
+  dir_include_server / 'catalog',
   dir_include_server / 'catalog',
 ]
 
index b940c5cd3d6a48e7aa677b4dc0ebd4d57692f7a5..7d734d92dabc40f7a7e28e2ef957b2e4bfbf8632 100644 (file)
@@ -173,6 +173,7 @@ install_subdir('catalog',
   exclude_files: [
     '.gitignore',
     'Makefile',
+    'README',
     'duplicate_oids',
     'meson.build',
     'reformat_dat_file.pl',