diff --git a/root/README.md b/root/README.md
index 500ceda8a..17e699435 100644
--- a/root/README.md
+++ b/root/README.md
@@ -310,7 +310,8 @@ environment variables:
exactly like the official binaries. No `PGHOST`, no `/run/postgresql`.
- **Zero-env PL languages.** `plperl.so`/`pltcl.so`/`plpython3.so` carry
RUNPATHs pointing at from-source `/opt`-prefixed runtimes built in
- `ppg:common:deps:tarballs` (`root/ppg/common/deps/tarballs/`): `percona-perl`,
+ `ppg:common:deps:tarballs` (`root/ppg/common/deps/tarballs/`): `percona-perl526`
+ (EL8) / `percona-perl532` (EL9),
`percona-tcl` (8.6.10) and `percona-python3` (3.12.13).
Every path (`@INC`, `TCL_LIBRARY`, `sys.prefix`) is compiled into those
runtimes, so all three PLs work even under a bare `postgres -D` start from
@@ -326,7 +327,8 @@ environment variables:
not NEED `libreadline`; `bin/psql` must be the non-ELF wrapper with
byte-clean stdout (no bare `cd -`).
- **Lean GDAL/PROJ.** PostGIS's `libgdal`/`libproj` come from the
- `percona-gdal` / `percona-proj` packages in `ppg:common:deps` — from-source,
+ `percona-gdal38`/`percona-gdal313` and `percona-proj96`/`percona-proj98`
+ packages (one per EL base) in `ppg:common:deps:tarballs` — from-source,
`/opt`-prefixed, built with the option set PostGIS actually needs. EPEL's
fully-optioned `gdal-libs` dragged ~70 surplus shared objects into the
artifact, among them `libflexiblas`, whose ELF constructor `abort()`s when
diff --git a/root/ppg/common/deps/tarballs/percona-gdal/obs/_service b/root/ppg/common/deps/tarballs/percona-gdal/obs/_service
deleted file mode 100644
index 8abe68253..000000000
--- a/root/ppg/common/deps/tarballs/percona-gdal/obs/_service
+++ /dev/null
@@ -1,21 +0,0 @@
-
-
-
- download.osgeo.org
- https
- /gdal/%!{GIS_GDAL_EL8_VERSION}/gdal-%!{GIS_GDAL_EL8_VERSION}.tar.xz
- gdal-%!{GIS_GDAL_EL8_VERSION}.tar.xz
-
-
- download.osgeo.org
- https
- /gdal/%!{GIS_GDAL_VERSION}/gdal-%!{GIS_GDAL_VERSION}.tar.xz
- gdal-%!{GIS_GDAL_VERSION}.tar.xz
-
-
diff --git a/root/ppg/common/deps/tarballs/percona-gdal313/obs/_service b/root/ppg/common/deps/tarballs/percona-gdal313/obs/_service
new file mode 100644
index 000000000..f2121dde9
--- /dev/null
+++ b/root/ppg/common/deps/tarballs/percona-gdal313/obs/_service
@@ -0,0 +1,11 @@
+
+
+
+ download.osgeo.org
+ https
+ /gdal/%!{GIS_GDAL_VERSION}/gdal-%!{GIS_GDAL_VERSION}.tar.xz
+ gdal-%!{GIS_GDAL_VERSION}.tar.xz
+
+
diff --git a/root/ppg/common/deps/tarballs/percona-gdal/package.yaml b/root/ppg/common/deps/tarballs/percona-gdal313/package.yaml
similarity index 82%
rename from root/ppg/common/deps/tarballs/percona-gdal/package.yaml
rename to root/ppg/common/deps/tarballs/percona-gdal313/package.yaml
index c85ad390e..a9181d029 100644
--- a/root/ppg/common/deps/tarballs/percona-gdal/package.yaml
+++ b/root/ppg/common/deps/tarballs/percona-gdal313/package.yaml
@@ -20,8 +20,8 @@ description: |
libgdal inside the binary tarball only — the shipped PostGIS RPMs keep
resolving to gdal38-libs/gdal313-libs on user systems.
- RockyLinux_8, RockyLinux_9.6 and RockyLinux_9 only: these are the
- tarball build bases (ssl1.1 / ssl3 / ssl3.5).
+ This package is the RHEL 9 build (RockyLinux_9.6 / RockyLinux_9,
+ tarballs ssl3 / ssl3.5); percona-gdal38 is the RHEL 8 one.
-# Builds on every repo of ppg:common:deps:tarballs (one per tarball EL
-# base: RockyLinux_8=ssl1.1, RockyLinux_9.6=ssl3, RockyLinux_9=ssl3.5).
+build:
+ RockyLinux_8: false
diff --git a/root/ppg/common/deps/tarballs/percona-gdal313/rpm/percona-gdal313.spec b/root/ppg/common/deps/tarballs/percona-gdal313/rpm/percona-gdal313.spec
new file mode 100644
index 000000000..faac51d4b
--- /dev/null
+++ b/root/ppg/common/deps/tarballs/percona-gdal313/rpm/percona-gdal313.spec
@@ -0,0 +1,312 @@
+# PERCONA PACKAGE for ppg:common:deps:tarballs (RockyLinux_8, RockyLinux_9.6, RockyLinux_9).
+#
+# /opt-prefixed GDAL runtime consumed by the Percona PostgreSQL binary
+# tarball (2026-07 tarball QA round, task 22).
+#
+# Why this exists: the tarball bundles the RPM-built postgis_raster.so,
+# which links libgdal.so.NN, so the tarball has to carry a libgdal. Using
+# EPEL's was a disaster on two counts:
+#
+# 1. EPEL builds GDAL with every optional driver enabled, so libgdal
+# drags ~70 surplus shared objects into the tarball (armadillo,
+# poppler, hdf4/hdf5, netcdf, OPeNDAP, xerces, libkml, unixODBC,
+# mariadb, cfitsio, ogdi, jasper/openjpeg, ...). Among them is a
+# BLAS/LAPACK chain via armadillo whose FlexiBLAS ELF constructor
+# abort()s on Rocky hosts because its dlopen'ed backend plugin is
+# not (and cannot sanely be) bundled, and it pulls libtirpc /
+# libexpat / libpcre2-posix which minimal target hosts lack.
+# 2. EPEL's libgdal has its data directory compiled to /usr/share/gdal,
+# a path that does not exist on the tarball's target hosts.
+#
+# This package builds GDAL from source with the prefix /opt/percona-gdal
+# and exactly the external libraries the OFFICIAL Percona tarball's libgdal
+# links (derived from `readelf -d` on the official artifact's
+# libgdal.so.36) and every other external library off
+# (GDAL_USE_EXTERNAL_LIBS=OFF). All built-in drivers are compiled, as the
+# autotools build did; the ones that need a library outside that set are
+# left out by GDAL's CMake (see %%build). Two deliberate departures from that list: libgeotiff is GDAL's
+# bundled copy (no libgeotiff17 in the tarball) and libspatialite is not
+# used at all. The data directory is compiled to
+# /opt/percona-gdal/share/gdal, so GDAL finds its resource files with ZERO
+# environment variables, and PROJ comes from percona-proj, whose proj.db
+# likewise resolves from a compiled-in path. GEOS is the PGDG-mirrored
+# geos315 (/usr/geos315) that PostGIS links too; the tarball bundles it.
+#
+# Version is per base and follows the PGDG-mirrored GDAL that the shipped
+# PostGIS RPMs link on that base (ppg:common:deps:postgis gdal38/gdal313,
+# root/macros.yaml GIS_GDAL_*) — the tarball just substitutes the bundled
+# file, so ours must be a drop-in:
+#
+# RHEL 8 (ssl1.1 tarball): GDAL 3.8.5 (gdal38) -> libgdal.so.34
+# RHEL 9 (ssl3/ssl3.5 tarballs): GDAL 3.13.3 (gdal313) -> libgdal.so.39
+#
+# We deliberately do NOT filter the auto-generated
+# libgdal.so.NN()(64bit) Provides: the ssl chroots that assemble the
+# tarball use a project-config `Prefer:` to let this package satisfy
+# PostGIS's SONAME Requires instead of gdal38-libs/gdal313-libs. Everything
+# installs under /opt/percona-gdal, so nothing shadows a system package
+# on a normal install, and ppg:common:deps is publish=false project-wide.
+
+%global gdal_prefix /opt/percona-gdal
+%global proj_prefix /opt/percona-proj
+
+# PERCONA: no link-time optimization. RHEL 9's %%optflags carry -flto=auto,
+# and libgdal is big enough that the final link degenerates into
+# "lto-wrapper: using serial compilation of 128 LTRANS jobs" — minutes of
+# single-threaded work that risks an OBS build timeout for no benefit.
+# Upstream does not enable LTO by default either. (RHEL 8's optflags do
+# not enable LTO, so this is a no-op there.)
+%global _lto_cflags %{nil}
+
+# PERCONA: one package per tarball base (percona-gdal38: RHEL 8,
+# percona-gdal313: RHEL 9), each with a single upstream version.
+%global gdal_version %!{GIS_GDAL_VERSION}
+%global gdal_soname 39
+# GDAL's CMake build installs the resource files to, and compiles INST_DATA
+# as, //gdal (gdal.cmake sets
+# GDAL_RESOURCE_PATH itself, so it cannot be overridden from the command
+# line). CMAKE_INSTALL_DATADIR=share below makes that this path.
+%global gdal_datadir %{gdal_prefix}/share/gdal
+# geos315 from ppg:common:deps:postgis, the GEOS PostGIS links.
+%global geos_prefix /usr/geos315
+
+Name: percona-gdal%!{GIS_GDAL_MAJOR}
+Version: %{gdal_version}
+Release: 1%{?dist}
+Summary: GDAL runtime under /opt/percona-gdal for the Percona PostgreSQL binary tarball
+License: MIT
+URL: https://gdal.org/
+Source0: gdal-%!{GIS_GDAL_VERSION}.tar.xz
+
+# PERCONA: an EXPLICIT dependency on our own PROJ, not just the automatic
+# libproj.so.NN()(64bit) ELF requires. That auto-requires is ambiguous:
+# proj96/proj98 (and EPEL's proj-libs on EL9) provide the very same
+# libproj.so.25 symbol, so a plain `dnf install percona-gdal` could
+# satisfy it with one of those, leaving
+# /opt/percona-proj/lib absent, libgdal's rpath dead and the whole
+# compiled-in-data-path mechanism broken. The point of this package is
+# *our* libproj, not any libproj with a matching SONAME.
+Requires: percona-proj%!{GIS_PROJ_MAJOR}
+
+BuildRequires: gcc
+BuildRequires: gcc-c++
+BuildRequires: make
+BuildRequires: cmake >= 3.16
+# PERCONA: our own /opt PROJ — same SONAME as the libproj PostGIS linked,
+# with the data path compiled to /opt/percona-proj/share/proj.
+BuildRequires: percona-proj%!{GIS_PROJ_MAJOR}
+# The driver set, one BuildRequires per NEEDED entry of the official
+# tarball's libgdal (see the header comment). libgeotiff is GDAL's bundled
+# copy (GDAL_USE_GEOTIFF_INTERNAL) and libspatialite is not used, so
+# no libgeotiff or libspatialite development package is needed here.
+BuildRequires: zlib-devel
+BuildRequires: libcurl-devel
+BuildRequires: libxml2-devel
+BuildRequires: openssl-devel
+BuildRequires: libzstd-devel
+BuildRequires: xz-devel
+BuildRequires: libjpeg-turbo-devel
+BuildRequires: libtiff-devel
+BuildRequires: libpng-devel
+BuildRequires: sqlite-devel
+BuildRequires: freexl-devel
+BuildRequires: expat-devel
+# PERCONA: the PGDG-mirrored GEOS PostGIS links (ppg:common:deps:postgis),
+# under /usr/geos315. Its package ships geos-config and geos_c.h but no
+# CMake config, so GDAL's FindGEOS finds it through CMAKE_PREFIX_PATH.
+BuildRequires: geos315-devel
+BuildRequires: json-c-devel
+BuildRequires: pcre2-devel
+BuildRequires: lz4-devel
+
+%description
+GDAL %{version} built from the upstream source with the prefix
+/opt/percona-gdal and only the external libraries the official Percona PostgreSQL
+tarball's libgdal links, so the binary tarball carries a handful of
+shared objects instead of the ~70 that EPEL's fully-optioned gdal-libs
+drags in. The GDAL data directory is compiled to
+/opt/percona-gdal/share/gdal and PROJ comes from percona-proj, so both
+resolve their resource files without any environment variables. This is the
+RHEL 9 build: its SONAME (libgdal.so.39) matches the libgdal
+of gdal313 that the shipped PostGIS RPMs link, making it a drop-in
+replacement inside the tarball. Consumed by the
+tarball build; not intended for standalone installation.
+
+%prep
+%setup -q -n gdal-%{version}
+
+%build
+# PERCONA: plain cmake, not %%cmake — the distro macro forces /usr + lib64
+# (and on EL8 CMAKE_SKIP_RPATH=ON), and we need a self-contained /opt tree
+# with our own RUNPATH.
+#
+# RUNPATH (CMAKE_INSTALL_RPATH, a CMake ;-list; bindings are off, so no
+# Python build consumes it):
+# %%{proj_prefix}/lib — our libproj, in the RPM install layout.
+# $ORIGIN — libgdal's own directory, for the tarball, which flattens
+# libproj/libgeos_c into the same lib/ dir as libgdal. Not redundant:
+# postgis_raster-3.so's own RUNPATH does NOT help here, because
+# DT_RUNPATH is not inherited down the load chain — it applies only to
+# that object's own NEEDED entries.
+# %%{geos_prefix}/lib64 — geos315's libgeos_c, in the RPM install layout.
+# The tarball's build-tarball.sh rewrites all of this to $ORIGIN/../lib
+# once it has bundled the libraries.
+# CMAKE_INSTALL_DATADIR=share: GDAL compiles INST_DATA as
+# /share/gdal (see %%{gdal_datadir} above), so the resource files
+# (gdalicon.png, the .csv/.json tables, ...) are found with no GDAL_DATA
+# in the environment.
+# CMAKE_PREFIX_PATH: our /opt PROJ (its CMake config, never a distro PROJ)
+# and geos315's geos-config/headers/library.
+# GDAL_USE_EXTERNAL_LIBS=OFF: every external library is off unless named
+# below — the CMake form of the autotools build's long --without- list
+# (armadillo, the one that drags the FlexiBLAS/BLAS/LAPACK chain whose
+# ELF constructor abort()s on Rocky hosts, hdf4/5, netcdf, poppler,
+# xerces, libkml, ODBC, mysql, openjpeg, webp, PostgreSQL, ...).
+# GDAL_USE_=ON then makes a missing library fatal instead of silently
+# dropping it. GDAL_USE_POSTGRESQL=OFF is spelled out anyway: the tarball
+# build never had the PostgreSQL driver (--without-pg).
+# Internal copies: libgeotiff (GDAL_USE_GEOTIFF_INTERNAL, so libgeotiff17
+# does not enter the tarball), qhull and gif (as --with-qhull/gif=internal
+# did). zlib/tiff/png/jpeg/json-c
+# are the system libraries (GDAL_USE_*_INTERNAL default to OFF when the
+# external one is ON), as the old --with-=/usr forced.
+# Drivers: GDAL_BUILD_OPTIONAL_DRIVERS/OGR_BUILD_OPTIONAL_DRIVERS=ON keep
+# the driver set of the autotools build, which compiled every built-in
+# driver. That does not widen the library set: a driver that needs an
+# external library is declared with gdal_dependent_format /
+# ogr_dependent_driver (cmake/helpers/GdalDriverHelper.cmake), whose
+# cmake_dependent_option forces GDAL_ENABLE_DRIVER_ / OGR_ENABLE_DRIVER_
+# OFF unless its GDAL_USE_ condition holds, and every GDAL_USE_
+# outside the list below is OFF through GDAL_USE_EXTERNAL_LIBS=OFF. No
+# driver is named here, so check_depend_condition never has a user-set
+# driver to fail on.
+# GDAL_USE_ICONV=ON: glibc's iconv, which the autotools build picked up by
+# default (CPLRecode); no extra library.
+# GDAL_HIDE_INTERNAL_SYMBOLS=ON: upstream's default, as
+# --with-hide-internal-symbols; keeps libgdal from re-exporting the
+# bundled geotiff/qhull symbols.
+# BUILD_APPS=OFF: the CLI tools never reach the tarball (build-tarball.sh
+# deletes bin/).
+mkdir -p build
+cd build
+cmake .. \
+ -DCMAKE_BUILD_TYPE=Release \
+ -DCMAKE_INSTALL_PREFIX=%{gdal_prefix} \
+ -DCMAKE_INSTALL_LIBDIR=lib \
+ -DCMAKE_INSTALL_DATADIR=share \
+ -DCMAKE_C_FLAGS="%{optflags}" \
+ -DCMAKE_CXX_FLAGS="%{optflags}" \
+ -DCMAKE_SHARED_LINKER_FLAGS="%{?__global_ldflags}" \
+ -DCMAKE_INSTALL_RPATH='%{gdal_prefix}/lib;%{proj_prefix}/lib;$ORIGIN;%{geos_prefix}/lib64' \
+ -DCMAKE_PREFIX_PATH="%{proj_prefix};%{geos_prefix}" \
+ -DPROJ_ROOT=%{proj_prefix} \
+ -DBUILD_SHARED_LIBS=ON \
+ -DBUILD_APPS=OFF \
+ -DBUILD_TESTING=OFF \
+ -DBUILD_PYTHON_BINDINGS=OFF \
+ -DBUILD_JAVA_BINDINGS=OFF \
+ -DBUILD_CSHARP_BINDINGS=OFF \
+ -DGDAL_HIDE_INTERNAL_SYMBOLS=ON \
+ -DGDAL_USE_EXTERNAL_LIBS=OFF \
+ -DGDAL_BUILD_OPTIONAL_DRIVERS=ON \
+ -DOGR_BUILD_OPTIONAL_DRIVERS=ON \
+ -DGDAL_USE_GEOTIFF_INTERNAL=ON \
+ -DGDAL_USE_TIFF_INTERNAL=OFF \
+ -DGDAL_USE_QHULL_INTERNAL=ON \
+ -DGDAL_USE_GIF_INTERNAL=ON \
+ -DGDAL_USE_ZLIB=ON \
+ -DGDAL_USE_CURL=ON \
+ -DGDAL_USE_LIBXML2=ON \
+ -DGDAL_USE_OPENSSL=ON \
+ -DGDAL_USE_ZSTD=ON \
+ -DGDAL_USE_LIBLZMA=ON \
+ -DGDAL_USE_JPEG=ON \
+ -DGDAL_USE_TIFF=ON \
+ -DGDAL_USE_PNG=ON \
+ -DGDAL_USE_SQLITE3=ON \
+ -DGDAL_USE_FREEXL=ON \
+ -DGDAL_USE_EXPAT=ON \
+ -DGDAL_USE_JSONC=ON \
+ -DGDAL_USE_GEOS=ON \
+ -DGDAL_USE_ICONV=ON \
+ -DGDAL_USE_PCRE2=ON \
+ -DGDAL_USE_LZ4=ON \
+ -DGDAL_USE_SPATIALITE=OFF \
+ -DGDAL_USE_POSTGRESQL=OFF
+
+make %{?_smp_mflags}
+
+%install
+make -C build install DESTDIR=%{buildroot}
+
+# PERCONA: hard gates on the three properties this package exists for.
+#
+# 1. SONAME parity. The package is only useful as a drop-in for the libgdal
+# the shipped PostGIS RPMs linked against, so assert the SONAME we
+# promised for this base actually came out. Without this, a source-URL
+# bump — or this package being built on the wrong base — would silently
+# produce a library that is
+# no longer ABI-compatible with postgis_raster.
+test -e %{buildroot}%{gdal_prefix}/lib/libgdal.so.%{gdal_soname}
+# 2. The compiled-in data path. The resource files must actually BE in the
+# directory libgdal was told about: GDAL also carries an independent
+# /share/gdal fallback string, so grepping the library alone
+# would pass even with a wrong data dir. The third test catches a
+# /share/gdal/gdal doubling (what GDAL 3.4.3's autotools build
+# produced with --datadir=/share/gdal).
+grep -q '%{gdal_datadir}' %{buildroot}%{gdal_prefix}/lib/libgdal.so.%{gdal_soname}
+test -s %{buildroot}%{gdal_datadir}/gdalicon.png
+test ! -d %{buildroot}%{gdal_datadir}/gdal
+# 3. A driver surface with none of the libraries the official tarball's
+# libgdal does without. libgeotiff and libspatialite joined the list
+# with the CMake build: geotiff is GDAL's bundled copy and spatialite
+# is off, so a NEEDED entry for either means the configuration slipped
+# (and would drag libgeotiff17/libspatialite50 into the tarball).
+for bad in libarmadillo libflexiblas libpoppler libhdf5 libmfhdf libnetcdf \
+ libdap libxerces libkmlbase libodbc libmariadb libcfitsio libogdi \
+ libjasper libopenjp2 libtirpc libwebp libgta libpq \
+ libgeotiff libspatialite; do
+ if readelf -d %{buildroot}%{gdal_prefix}/lib/libgdal.so.%{gdal_soname} | grep -q "$bad"; then
+ echo "ERROR: libgdal links $bad — driver set is not lean" >&2
+ exit 1
+ fi
+done
+# 4. The two GIS libraries libgdal must take from the right place: our
+# /opt PROJ (libproj.so.25) and geos315's libgeos_c, each reachable
+# through libgdal's own RUNPATH.
+readelf -d %{buildroot}%{gdal_prefix}/lib/libgdal.so.%{gdal_soname} | grep -q 'NEEDED.*\[libproj\.so\.25\]'
+readelf -d %{buildroot}%{gdal_prefix}/lib/libgdal.so.%{gdal_soname} | grep -q 'NEEDED.*\[libgeos_c\.so\.1\]'
+readelf -d %{buildroot}%{gdal_prefix}/lib/libgdal.so.%{gdal_soname} | grep -E '\((RUNPATH|RPATH)\)' | grep -q '%{proj_prefix}/lib'
+readelf -d %{buildroot}%{gdal_prefix}/lib/libgdal.so.%{gdal_soname} | grep -E '\((RUNPATH|RPATH)\)' | grep -q '%{geos_prefix}/lib64'
+
+%files
+%license LICENSE.TXT
+%{gdal_prefix}
+
+%changelog
+* Tue Oct 20 2026 Percona Development - %{version}-%{release}
+- Split percona-gdal into one package per tarball base so each OBS
+ package builds a single version: percona-gdal38 (RHEL 8, GDAL 3.8.5)
+ and percona-gdal313 (RHEL 9, GDAL 3.13.3). Install prefix unchanged.
+
+* Sun Oct 18 2026 Percona Development - %{version}-%{release}
+- Follow the PGDG-mirrored GDAL that PostGIS now links: 3.8.5 on RHEL 8
+ (gdal38, libgdal.so.34) and 3.13.3 on RHEL 9 (gdal313,
+ libgdal.so.39), versions from root/macros.yaml.
+- Build with CMake (GDAL dropped autotools in 3.6): same external
+ library set, every other one off; all built-in drivers, as before.
+- GDAL's bundled libgeotiff instead of the system one, no
+ libspatialite, GEOS from geos315 (/usr/geos315).
+
+* Wed Sep 02 2026 Percona Build/Release Team - %{version}-%{release}
+- Drop ExcludeArch aarch64: the binary tarball (ppg:staging:NN:tarballs)
+ now builds for aarch64 too, so this runtime is no longer dead weight
+ on that arch.
+
+* Tue Aug 25 2026 Percona Build/Release Team - %{version}-%{release}
+- Initial /opt/percona-gdal runtime for the Percona PostgreSQL binary
+ tarball: GDAL 3.0.4 on RHEL 8 (libgdal.so.26) and GDAL 3.4.3 on
+ RHEL 9 (libgdal.so.30), restricted to the official tarball's driver
+ set (no armadillo/FlexiBLAS, hdf, netcdf, OPeNDAP, poppler, xerces,
+ libkml, ODBC, mariadb, ...) and with the GDAL data directory compiled
+ to /opt/percona-gdal/share/gdal (tarball QA task 22).
diff --git a/root/ppg/common/deps/tarballs/percona-gdal38/obs/_service b/root/ppg/common/deps/tarballs/percona-gdal38/obs/_service
new file mode 100644
index 000000000..f2439491e
--- /dev/null
+++ b/root/ppg/common/deps/tarballs/percona-gdal38/obs/_service
@@ -0,0 +1,11 @@
+
+
+
+ download.osgeo.org
+ https
+ /gdal/%!{GIS_GDAL_EL8_VERSION}/gdal-%!{GIS_GDAL_EL8_VERSION}.tar.xz
+ gdal-%!{GIS_GDAL_EL8_VERSION}.tar.xz
+
+
diff --git a/root/ppg/common/deps/tarballs/percona-gdal38/package.yaml b/root/ppg/common/deps/tarballs/percona-gdal38/package.yaml
new file mode 100644
index 000000000..d8db65c3e
--- /dev/null
+++ b/root/ppg/common/deps/tarballs/percona-gdal38/package.yaml
@@ -0,0 +1,28 @@
+title: /opt-prefixed lean GDAL runtime for the PPG binary tarball
+description: |
+ GDAL built from upstream source with the install prefix
+ /opt/percona-gdal and only the driver set the official Percona
+ PostgreSQL tarball's libgdal links, so the binary tarball carries a
+ handful of shared objects instead of the ~70 that EPEL's
+ fully-optioned gdal-libs drags in (armadillo/FlexiBLAS — whose ELF
+ constructor abort()s on Rocky hosts — poppler, hdf4/hdf5, netcdf,
+ OPeNDAP, xerces, libkml, unixODBC, mariadb, cfitsio, ogdi, ...). The
+ GDAL data directory is compiled to /opt/percona-gdal/share/gdal and
+ PROJ comes from percona-proj, so both resolve their resource files
+ with zero environment variables. Built with CMake: GDAL's bundled
+ libgeotiff, no libspatialite, GEOS from geos315
+ (ppg:common:deps:postgis).
+
+ Version follows the PGDG-mirrored GDAL that the shipped PostGIS RPMs
+ link (ppg:common:deps:postgis): RHEL 8 -> GDAL 3.8.5 like gdal38
+ (libgdal.so.34), RHEL 9 -> GDAL 3.13.3 like gdal313 (libgdal.so.39).
+ That makes it a drop-in replacement for gdal38-libs/gdal313-libs'
+ libgdal inside the binary tarball only — the shipped PostGIS RPMs keep
+ resolving to gdal38-libs/gdal313-libs on user systems.
+
+ This package is the RHEL 8 build (RockyLinux_8, tarball ssl1.1);
+ percona-gdal313 is the RHEL 9 one.
+
+build:
+ RockyLinux_9: false
+ RockyLinux_9.6: false
diff --git a/root/ppg/common/deps/tarballs/percona-gdal/rpm/percona-gdal.spec b/root/ppg/common/deps/tarballs/percona-gdal38/rpm/percona-gdal38.spec
similarity index 92%
rename from root/ppg/common/deps/tarballs/percona-gdal/rpm/percona-gdal.spec
rename to root/ppg/common/deps/tarballs/percona-gdal38/rpm/percona-gdal38.spec
index 496c417d4..8d3410c5f 100644
--- a/root/ppg/common/deps/tarballs/percona-gdal/rpm/percona-gdal.spec
+++ b/root/ppg/common/deps/tarballs/percona-gdal38/rpm/percona-gdal38.spec
@@ -58,16 +58,10 @@
# not enable LTO, so this is a no-op there.)
%global _lto_cflags %{nil}
-# PERCONA: base-specific upstream version + which Source to unpack.
-%if 0%{?rhel} == 8
+# PERCONA: one package per tarball base (percona-gdal38: RHEL 8,
+# percona-gdal313: RHEL 9), each with a single upstream version.
%global gdal_version %!{GIS_GDAL_EL8_VERSION}
-%global gdal_srcidx 0
%global gdal_soname 34
-%else
-%global gdal_version %!{GIS_GDAL_VERSION}
-%global gdal_srcidx 1
-%global gdal_soname 39
-%endif
# GDAL's CMake build installs the resource files to, and compiles INST_DATA
# as, //gdal (gdal.cmake sets
# GDAL_RESOURCE_PATH itself, so it cannot be overridden from the command
@@ -76,16 +70,13 @@
# geos315 from ppg:common:deps:postgis, the GEOS PostGIS links.
%global geos_prefix /usr/geos315
-Name: percona-gdal
+Name: percona-gdal%!{GIS_GDAL_EL8_MAJOR}
Version: %{gdal_version}
Release: 1%{?dist}
Summary: GDAL runtime under /opt/percona-gdal for the Percona PostgreSQL binary tarball
License: MIT
URL: https://gdal.org/
-# PERCONA: both tarballs are always fetched by the _service; %%prep
-# unpacks only the one that matches the base being built.
Source0: gdal-%!{GIS_GDAL_EL8_VERSION}.tar.xz
-Source1: gdal-%!{GIS_GDAL_VERSION}.tar.xz
# PERCONA: an EXPLICIT dependency on our own PROJ, not just the automatic
# libproj.so.NN()(64bit) ELF requires. That auto-requires is ambiguous:
@@ -95,7 +86,7 @@ Source1: gdal-%!{GIS_GDAL_VERSION}.tar.xz
# /opt/percona-proj/lib absent, libgdal's rpath dead and the whole
# compiled-in-data-path mechanism broken. The point of this package is
# *our* libproj, not any libproj with a matching SONAME.
-Requires: percona-proj
+Requires: percona-proj%!{GIS_PROJ_EL8_MAJOR}
BuildRequires: gcc
BuildRequires: gcc-c++
@@ -103,7 +94,7 @@ BuildRequires: make
BuildRequires: cmake >= 3.16
# PERCONA: our own /opt PROJ — same SONAME as the libproj PostGIS linked,
# with the data path compiled to /opt/percona-proj/share/proj.
-BuildRequires: percona-proj
+BuildRequires: percona-proj%!{GIS_PROJ_EL8_MAJOR}
# The driver set, one BuildRequires per NEEDED entry of the official
# tarball's libgdal (see the header comment). libgeotiff is GDAL's bundled
# copy (GDAL_USE_GEOTIFF_INTERNAL) and libspatialite is not used, so
@@ -125,15 +116,10 @@ BuildRequires: expat-devel
# CMake config, so GDAL's FindGEOS finds it through CMAKE_PREFIX_PATH.
BuildRequires: geos315-devel
BuildRequires: json-c-devel
-%if 0%{?rhel} == 8
# PCRE1, not PCRE2, on EL8: the GDAL 3.0.4 this replaces had no PCRE2
# support, so its libgdal linked libpcre.so.1 (and no liblz4); keep the
# same library set.
BuildRequires: pcre-devel
-%else
-BuildRequires: pcre2-devel
-BuildRequires: lz4-devel
-%endif
%description
GDAL %{version} built from the upstream source with the prefix
@@ -142,16 +128,14 @@ tarball's libgdal links, so the binary tarball carries a handful of
shared objects instead of the ~70 that EPEL's fully-optioned gdal-libs
drags in. The GDAL data directory is compiled to
/opt/percona-gdal/share/gdal and PROJ comes from percona-proj, so both
-resolve their resource files without any environment variables. The
-upstream version is picked per base so the SONAME matches the libgdal
-that the shipped PostGIS RPMs linked against (RHEL 8: 3.8.5 /
-libgdal.so.34 like gdal38, RHEL 9: 3.13.3 / libgdal.so.39 like gdal313),
-making this a drop-in replacement inside the tarball. Consumed by the
+resolve their resource files without any environment variables. This is the
+RHEL 8 build: its SONAME (libgdal.so.34) matches the libgdal
+of gdal38 that the shipped PostGIS RPMs link, making it a drop-in
+replacement inside the tarball. Consumed by the
tarball build; not intended for standalone installation.
%prep
-# PERCONA: -T -b %%{gdal_srcidx} — unpack only the base-matching tarball.
-%setup -q -T -b %{gdal_srcidx} -n gdal-%{version}
+%setup -q -n gdal-%{version}
%build
# PERCONA: plain cmake, not %%cmake — the distro macro forces /usr + lib64
@@ -247,14 +231,9 @@ cmake .. \
-DGDAL_USE_JSONC=ON \
-DGDAL_USE_GEOS=ON \
-DGDAL_USE_ICONV=ON \
-%if 0%{?rhel} == 8
-DGDAL_USE_PCRE2=OFF \
-DGDAL_USE_PCRE=ON \
-DGDAL_USE_LZ4=OFF \
-%else
- -DGDAL_USE_PCRE2=ON \
- -DGDAL_USE_LZ4=ON \
-%endif
-DGDAL_USE_SPATIALITE=OFF \
-DGDAL_USE_POSTGRESQL=OFF
@@ -268,8 +247,8 @@ make -C build install DESTDIR=%{buildroot}
# 1. SONAME parity. The package is only useful as a drop-in for the libgdal
# the shipped PostGIS RPMs linked against, so assert the SONAME we
# promised for this base actually came out. Without this, a source-URL
-# bump — or this spec being built on an unexpected %%{?rhel} where the
-# %%if picks the wrong branch — would silently produce a library that is
+# bump — or this package being built on the wrong base — would silently
+# produce a library that is
# no longer ABI-compatible with postgis_raster.
test -e %{buildroot}%{gdal_prefix}/lib/libgdal.so.%{gdal_soname}
# 2. The compiled-in data path. The resource files must actually BE in the
@@ -308,6 +287,11 @@ readelf -d %{buildroot}%{gdal_prefix}/lib/libgdal.so.%{gdal_soname} | grep -E '\
%{gdal_prefix}
%changelog
+* Tue Oct 20 2026 Percona Development - %{version}-%{release}
+- Split percona-gdal into one package per tarball base so each OBS
+ package builds a single version: percona-gdal38 (RHEL 8, GDAL 3.8.5)
+ and percona-gdal313 (RHEL 9, GDAL 3.13.3). Install prefix unchanged.
+
* Sun Oct 18 2026 Percona Development - %{version}-%{release}
- Follow the PGDG-mirrored GDAL that PostGIS now links: 3.8.5 on RHEL 8
(gdal38, libgdal.so.34) and 3.13.3 on RHEL 9 (gdal313,
diff --git a/root/ppg/common/deps/tarballs/percona-gis-compat/rpm/percona-gis-compat.spec b/root/ppg/common/deps/tarballs/percona-gis-compat/rpm/percona-gis-compat.spec
index 5864cb733..659afbf40 100644
--- a/root/ppg/common/deps/tarballs/percona-gis-compat/rpm/percona-gis-compat.spec
+++ b/root/ppg/common/deps/tarballs/percona-gis-compat/rpm/percona-gis-compat.spec
@@ -97,8 +97,13 @@ Provides: libgeotiff17 = %!{GIS_LIBGEOTIFF_VERSION}
# The real runtimes this shim stands in for, plus the real geos315 that the
# tarball bundles as-is.
-Requires: percona-gdal
-Requires: percona-proj
+%if 0%{?rhel} == 8
+Requires: percona-gdal%!{GIS_GDAL_EL8_MAJOR}
+Requires: percona-proj%!{GIS_PROJ_EL8_MAJOR}
+%else
+Requires: percona-gdal%!{GIS_GDAL_MAJOR}
+Requires: percona-proj%!{GIS_PROJ_MAJOR}
+%endif
Requires: geos%!{GIS_GEOS_MAJOR}
%description
diff --git a/root/ppg/common/deps/tarballs/percona-perl/obs/_service b/root/ppg/common/deps/tarballs/percona-perl526/obs/_service
similarity index 52%
rename from root/ppg/common/deps/tarballs/percona-perl/obs/_service
rename to root/ppg/common/deps/tarballs/percona-perl526/obs/_service
index 347a1f218..6781af361 100644
--- a/root/ppg/common/deps/tarballs/percona-perl/obs/_service
+++ b/root/ppg/common/deps/tarballs/percona-perl526/obs/_service
@@ -1,14 +1,10 @@
+
www.cpan.org
https
/src/5.0/perl-5.26.3.tar.gz
perl-5.26.3.tar.gz
-
- www.cpan.org
- https
- /src/5.0/perl-5.32.1.tar.gz
- perl-5.32.1.tar.gz
-
diff --git a/root/ppg/common/deps/tarballs/percona-perl/package.yaml b/root/ppg/common/deps/tarballs/percona-perl526/package.yaml
similarity index 63%
rename from root/ppg/common/deps/tarballs/percona-perl/package.yaml
rename to root/ppg/common/deps/tarballs/percona-perl526/package.yaml
index dfe578aac..b0535a5d7 100644
--- a/root/ppg/common/deps/tarballs/percona-perl/package.yaml
+++ b/root/ppg/common/deps/tarballs/percona-perl526/package.yaml
@@ -7,9 +7,10 @@ description: |
the distro perl of each build base (5.26.3 on EL8, 5.32.1 on EL9):
plperl.so is ABI-tied to the libperl it was compiled against
(DT_NEEDED libperl.so.5.26 / libperl.so.5.32). Installs only under
- /opt/percona-perl — nothing shadows system packages. RockyLinux_8,
- RockyLinux_9 and RockyLinux_9.6 only — the tarball build bases
- (ssl1.1 on EL8, ssl3 on the 9.6 vault).
+ /opt/percona-perl — nothing shadows system packages. This package
+ is the RHEL 8 build (RockyLinux_8, tarball ssl1.1);
+ percona-perl532 is the RHEL 9 one.
-# Builds on every repo of ppg:common:deps:tarballs (one per tarball EL
-# base: RockyLinux_8=ssl1.1, RockyLinux_9.6=ssl3, RockyLinux_9=ssl3.5).
+build:
+ RockyLinux_9: false
+ RockyLinux_9.6: false
diff --git a/root/ppg/common/deps/tarballs/percona-perl/rpm/percona-perl.spec b/root/ppg/common/deps/tarballs/percona-perl526/rpm/percona-perl526.spec
similarity index 94%
rename from root/ppg/common/deps/tarballs/percona-perl/rpm/percona-perl.spec
rename to root/ppg/common/deps/tarballs/percona-perl526/rpm/percona-perl526.spec
index 06442bae7..2aa2c6ce3 100644
--- a/root/ppg/common/deps/tarballs/percona-perl/rpm/percona-perl.spec
+++ b/root/ppg/common/deps/tarballs/percona-perl526/rpm/percona-perl526.spec
@@ -53,15 +53,11 @@
%global perl_prefix /opt/percona-perl
-# PERCONA: version MUST track the distro perl of each build base (see the
+# PERCONA: version MUST track the distro perl of its build base (see the
# ABI constraint above). The SONAME must equal plperl.so's DT_NEEDED.
-%if 0%{?rhel} == 8
+# One package per base: percona-perl526 (RHEL 8), percona-perl532 (RHEL 9).
%global perl_version 5.26.3
%global perl_soname libperl.so.5.26
-%else
-%global perl_version 5.32.1
-%global perl_soname libperl.so.5.32
-%endif
# PERCONA: this is a self-contained /opt runtime. Do not leak perl(...)
# provides (they would satisfy other packages' perl-module deps in the
@@ -73,15 +69,13 @@
# PERCONA: keep our /opt/percona-perl/bin/perl shebangs untouched.
%undefine __brp_mangle_shebangs
-Name: percona-perl
+Name: percona-perl526
Version: %{perl_version}
Release: 1%{?dist}
Summary: Perl runtime under /opt/percona-perl for the Percona PostgreSQL binary tarball
License: GPL-1.0-or-later OR Artistic-1.0-Perl
URL: https://www.perl.org/
-# PERCONA: both distro-matched versions ship as sources; %%{?rhel} picks.
Source0: perl-5.26.3.tar.gz
-Source1: perl-5.32.1.tar.gz
# PERCONA: 5.26-only — build against libxcrypt's crypt.h (no
# current_saltbits member); upstream dropped the code in 5.28.
Patch0: perl-5.26.3-crypt-libxcrypt.patch
@@ -104,12 +98,8 @@ environment variables. Consumed by the Percona PostgreSQL binary tarball
build; not intended for standalone installation.
%prep
-%if 0%{?rhel} == 8
%setup -q -n perl-%{perl_version}
%patch0 -p1
-%else
-%setup -q -T -b 1 -n perl-%{perl_version}
-%endif
%build
./Configure -des \
@@ -179,6 +169,12 @@ ln -sf %{perl_soname} %{buildroot}%{perl_prefix}/lib/%{perl_version}/CORE/libper
%{perl_prefix}
%changelog
+* Tue Oct 20 2026 Percona Development - %{version}-%{release}
+- Split percona-perl into one package per tarball base so each OBS
+ package builds a single version: percona-perl526 (RHEL 8, Perl
+ 5.26.3) and percona-perl532 (RHEL 9, Perl 5.32.1). Install prefix
+ unchanged.
+
* Tue Jul 28 2026 Percona Build/Release Team - 5.26.3-1
- Initial /opt/percona-perl runtime for the Percona PostgreSQL binary
tarball: distro-matched Perl (5.26.3 on EL8, 5.32.1 on EL9) built from
diff --git a/root/ppg/common/deps/tarballs/percona-perl/rpm/perl-5.26.3-crypt-libxcrypt.patch b/root/ppg/common/deps/tarballs/percona-perl526/rpm/perl-5.26.3-crypt-libxcrypt.patch
similarity index 100%
rename from root/ppg/common/deps/tarballs/percona-perl/rpm/perl-5.26.3-crypt-libxcrypt.patch
rename to root/ppg/common/deps/tarballs/percona-perl526/rpm/perl-5.26.3-crypt-libxcrypt.patch
diff --git a/root/ppg/common/deps/tarballs/percona-perl532/obs/_service b/root/ppg/common/deps/tarballs/percona-perl532/obs/_service
new file mode 100644
index 000000000..30be3e3b3
--- /dev/null
+++ b/root/ppg/common/deps/tarballs/percona-perl532/obs/_service
@@ -0,0 +1,10 @@
+
+
+
+ www.cpan.org
+ https
+ /src/5.0/perl-5.32.1.tar.gz
+ perl-5.32.1.tar.gz
+
+
diff --git a/root/ppg/common/deps/tarballs/percona-perl532/package.yaml b/root/ppg/common/deps/tarballs/percona-perl532/package.yaml
new file mode 100644
index 000000000..2c77958b7
--- /dev/null
+++ b/root/ppg/common/deps/tarballs/percona-perl532/package.yaml
@@ -0,0 +1,15 @@
+title: /opt-prefixed Perl runtime for the PPG binary tarball
+description: |
+ Perl built from upstream source with every install path compiled to
+ /opt/percona-perl, so the RPM-built plperl.so bundled into the Percona
+ PostgreSQL binary tarball resolves libperl and its @INC (strict.pm,
+ POSIX.pm, ...) with zero environment variables. The version MUST match
+ the distro perl of each build base (5.26.3 on EL8, 5.32.1 on EL9):
+ plperl.so is ABI-tied to the libperl it was compiled against
+ (DT_NEEDED libperl.so.5.26 / libperl.so.5.32). Installs only under
+ /opt/percona-perl — nothing shadows system packages. This package
+ is the RHEL 9 build (RockyLinux_9.6 / RockyLinux_9, tarballs ssl3 /
+ ssl3.5); percona-perl526 is the RHEL 8 one.
+
+build:
+ RockyLinux_8: false
diff --git a/root/ppg/common/deps/tarballs/percona-perl532/rpm/percona-perl532.spec b/root/ppg/common/deps/tarballs/percona-perl532/rpm/percona-perl532.spec
new file mode 100644
index 000000000..882266829
--- /dev/null
+++ b/root/ppg/common/deps/tarballs/percona-perl532/rpm/percona-perl532.spec
@@ -0,0 +1,179 @@
+# PERCONA PACKAGE for ppg:common:deps (RockyLinux_8 and RockyLinux_9 only).
+#
+# /opt-prefixed Perl runtime consumed by the Percona PostgreSQL binary
+# tarball (QA items 3 and 7 of the 2026-07 tarball QA round).
+#
+# Why this exists: the tarball bundles the RPM-built plperl.so, which
+# dlopens libperl and then loads strict.pm/POSIX.pm from the @INC paths
+# COMPILED INTO that libperl. The distro libperl's compiled @INC points at
+# /usr/share/perl5 and /usr/lib64/perl5 — paths that do not exist on the
+# tarball's target hosts — so plperl only worked when the server was
+# started through an env-exporting wrapper (PERL5LIB), and QA proved any
+# wrapper bypass breaks it. This package builds Perl from source with
+# every install path compiled to /opt/percona-perl, so plperl.so works
+# with ZERO environment variables — the official tarball's mechanism.
+#
+# ABI constraint (load-bearing): plperl.so is linked against the distro
+# libperl (DT_NEEDED libperl.so.5.26 on EL8, libperl.so.5.32 on EL9) and
+# was compiled against the distro perl's config.h. The version MUST equal
+# the distro perl per base (5.26.3 on EL8, 5.32.1 on EL9) and the
+# ABI-relevant Configure options MUST match the distro build. The
+# Configure invocation below replicates the Rocky Linux perl config_args
+# (captured verbatim from `perl -V:config_args` on Rocky 8.10
+# perl-5.26.3-423.el8_10 and Rocky 9 perl-5.32.1-483.el9) minus:
+# - all path flags (-Dprefix/-Dprivlib/-Darchlib/... -> /opt/percona-perl,
+# flat lib/ layout so libperl lands at lib//CORE/,
+# exactly where the tarball points plperl.so's RUNPATH);
+# - toolchain dressing (-Dccflags hardening specs, -Dldflags,
+# -Dccdlflags, -Dcf_by, -Doptimize=none + -DDEBUGGING=-g): replaced by
+# %%{optflags} and Configure's defaults. NOT ABI-relevant. Note the
+# distro's -Dccdlflags override is deliberately NOT replicated: the
+# default ccdlflags embed an rpath to /CORE, which our
+# off-path /opt layout needs so bin/perl finds libperl.so.5.xx;
+# - -Dusedtrace: SDT probes are interpreter-internal, no ABI effect,
+# and would add a systemtap-sdt-devel BuildRequires;
+# - -Dshrpdir=/usr/lib64: default (archlib/CORE) is what we want;
+# - -Di_gdbm: gdbm-devel is not in the default EL9 repos; i_gdbm only
+# gates the optional GDBM_File module, never loaded by plperl or any
+# tarball component, and does not affect the libperl ABI.
+# Everything ABI-relevant is kept identical: usethreads, useithreads,
+# useshrplib, use64bitint, uselargefiles, useperlio, archname
+# -linux-thread-multi, d_semctl_semun, the *_r_proto overrides,
+# usesitecustomize, and -Dlibperl so the SONAME matches plperl.so's
+# DT_NEEDED exactly.
+#
+# The full core module set is kept (strict, POSIX, Safe, Opcode are
+# load-bearing for plperl/plperlu). Man pages and pod documentation ship
+# as upstream installs them (under the /opt prefix, like the official
+# tarball's percona-perl/man tree).
+#
+# The name is deliberately distinct from the distro perl and everything
+# installs under /opt/percona-perl: nothing shadows system packages.
+# ppg:common:deps is publish=false project-wide.
+
+%global perl_prefix /opt/percona-perl
+
+# PERCONA: version MUST track the distro perl of its build base (see the
+# ABI constraint above). The SONAME must equal plperl.so's DT_NEEDED.
+# One package per base: percona-perl526 (RHEL 8), percona-perl532 (RHEL 9).
+%global perl_version 5.32.1
+%global perl_soname libperl.so.5.32
+
+# PERCONA: this is a self-contained /opt runtime. Do not leak perl(...)
+# provides (they would satisfy other packages' perl-module deps in the
+# repo) and do not require perl(...)/libperl (self-contained; libperl is
+# our own file). ELF requires on system libs (glibc, libxcrypt, libdb)
+# are kept.
+%global __provides_exclude_from ^%{perl_prefix}/.*$
+%global __requires_exclude ^(perl\\(|libperl)
+# PERCONA: keep our /opt/percona-perl/bin/perl shebangs untouched.
+%undefine __brp_mangle_shebangs
+
+Name: percona-perl532
+Version: %{perl_version}
+Release: 1%{?dist}
+Summary: Perl runtime under /opt/percona-perl for the Percona PostgreSQL binary tarball
+License: GPL-1.0-or-later OR Artistic-1.0-Perl
+URL: https://www.perl.org/
+Source0: perl-5.32.1.tar.gz
+
+BuildRequires: gcc
+BuildRequires: make
+BuildRequires: redhat-rpm-config
+BuildRequires: libxcrypt-devel
+BuildRequires: libdb-devel
+BuildRequires: findutils
+BuildRequires: tar
+BuildRequires: gzip
+
+%description
+Perl %{perl_version} built from the upstream source with every install
+path compiled to /opt/percona-perl, matching the distro perl version and
+ABI-relevant configuration so the RPM-built plperl.so resolves this
+libperl (SONAME %{perl_soname}) and its compiled-in @INC without any
+environment variables. Consumed by the Percona PostgreSQL binary tarball
+build; not intended for standalone installation.
+
+%prep
+%setup -q -n perl-%{perl_version}
+
+%build
+./Configure -des \
+ -Dcc=gcc \
+ -Doptimize="%{optflags}" \
+ -Dversion=%{perl_version} \
+ -Dmyhostname=localhost \
+ -Dperladmin=root@localhost \
+ -Dprefix=%{perl_prefix} \
+ -Dsiteprefix=%{perl_prefix} \
+ -Dvendorprefix=%{perl_prefix} \
+ -Dprivlib=%{perl_prefix}/lib/%{perl_version} \
+ -Darchlib=%{perl_prefix}/lib/%{perl_version} \
+ -Dsitelib=%{perl_prefix}/lib/%{perl_version} \
+ -Dsitearch=%{perl_prefix}/lib/%{perl_version} \
+ -Dvendorlib=%{perl_prefix}/lib/%{perl_version} \
+ -Dvendorarch=%{perl_prefix}/lib/%{perl_version} \
+ -Dscriptdir=%{perl_prefix}/bin \
+ -Dlibperl=%{perl_soname} \
+ -Darchname=%{_arch}-linux-thread-multi \
+ -Dusethreads \
+ -Duseithreads \
+ -Duseshrplib \
+ -Duse64bitint \
+ -Duselargefiles \
+ -Duseperlio \
+ -Dd_semctl_semun \
+ -Di_db \
+ -Ui_ndbm \
+ -Ui_gdbm \
+ -Di_shadow \
+ -Di_syslog \
+ -Dman3ext=3pm \
+ -Dinstallusrbinperl=n \
+ -Ubincompat5005 \
+ -Uversiononly \
+ -Dpager='/usr/bin/less -isr' \
+ -Dd_gethostent_r_proto \
+ -Ud_endhostent_r_proto \
+ -Ud_sethostent_r_proto \
+ -Ud_endprotoent_r_proto \
+ -Ud_setprotoent_r_proto \
+ -Ud_endservent_r_proto \
+ -Ud_setservent_r_proto \
+ -Dusesitecustomize
+
+make %{?_smp_mflags}
+
+%install
+make install DESTDIR=%{buildroot}
+
+# PERCONA: perl's make install ships the XS .so files AND the versioned
+# libperl (%{perl_soname}) mode 0555. The RockyLinux_9.6 (RHEL 9.6 EUS
+# vault) buildroot's brp-strip cannot rewrite read-only files ("strip:
+# unable to copy file ...; reason: Permission denied" fails the RPM
+# install step), while newer 9.x toolchains tolerated it. Make them
+# owner-writable, like the distro perl spec does — '*.so*' so the
+# versioned libperl is covered too.
+find %{buildroot}%{perl_prefix} -type f -name '*.so*' -exec chmod u+w {} +
+
+# PERCONA: unversioned libperl.so symlink next to the real SONAME file,
+# same convenience link the distro ships in its CORE directory.
+ln -sf %{perl_soname} %{buildroot}%{perl_prefix}/lib/%{perl_version}/CORE/libperl.so
+
+%files
+%license Copying Artistic
+%{perl_prefix}
+
+%changelog
+* Tue Oct 20 2026 Percona Development - %{version}-%{release}
+- Split percona-perl into one package per tarball base so each OBS
+ package builds a single version: percona-perl526 (RHEL 8, Perl
+ 5.26.3) and percona-perl532 (RHEL 9, Perl 5.32.1). Install prefix
+ unchanged.
+
+* Tue Jul 28 2026 Percona Build/Release Team - 5.26.3-1
+- Initial /opt/percona-perl runtime for the Percona PostgreSQL binary
+ tarball: distro-matched Perl (5.26.3 on EL8, 5.32.1 on EL9) built from
+ upstream source with Rocky's ABI-relevant Configure options and all
+ paths compiled to /opt/percona-perl, so the RPM-built plperl.so works
+ with zero environment variables (tarball QA items 3 and 7).
diff --git a/root/ppg/common/deps/tarballs/percona-proj/obs/_service b/root/ppg/common/deps/tarballs/percona-proj/obs/_service
deleted file mode 100644
index 0b7bbc437..000000000
--- a/root/ppg/common/deps/tarballs/percona-proj/obs/_service
+++ /dev/null
@@ -1,22 +0,0 @@
-
-
-
- download.osgeo.org
- https
- /proj/proj-%!{GIS_PROJ_EL8_VERSION}.tar.gz
- proj-%!{GIS_PROJ_EL8_VERSION}.tar.gz
-
-
- download.osgeo.org
- https
- /proj/proj-%!{GIS_PROJ_VERSION}.tar.gz
- proj-%!{GIS_PROJ_VERSION}.tar.gz
-
-
diff --git a/root/ppg/common/deps/tarballs/percona-proj96/obs/_service b/root/ppg/common/deps/tarballs/percona-proj96/obs/_service
new file mode 100644
index 000000000..660e713e8
--- /dev/null
+++ b/root/ppg/common/deps/tarballs/percona-proj96/obs/_service
@@ -0,0 +1,13 @@
+
+
+
+ download.osgeo.org
+ https
+ /proj/proj-%!{GIS_PROJ_EL8_VERSION}.tar.gz
+ proj-%!{GIS_PROJ_EL8_VERSION}.tar.gz
+
+
diff --git a/root/ppg/common/deps/tarballs/percona-proj/package.yaml b/root/ppg/common/deps/tarballs/percona-proj96/package.yaml
similarity index 71%
rename from root/ppg/common/deps/tarballs/percona-proj/package.yaml
rename to root/ppg/common/deps/tarballs/percona-proj96/package.yaml
index 1ea48e200..ea51c3179 100644
--- a/root/ppg/common/deps/tarballs/percona-proj/package.yaml
+++ b/root/ppg/common/deps/tarballs/percona-proj96/package.yaml
@@ -10,8 +10,9 @@ description: |
proj96/proj98's libproj inside the binary tarball only — the shipped
PostGIS RPMs keep resolving to proj96/proj98 on user systems.
- RockyLinux_8, RockyLinux_9.6 and RockyLinux_9 only: these are the
- tarball build bases (ssl1.1 / ssl3 / ssl3.5).
+ This package is the RHEL 8 build (RockyLinux_8, tarball ssl1.1);
+ percona-proj98 is the RHEL 9 one.
-# Builds on every repo of ppg:common:deps:tarballs (one per tarball EL
-# base: RockyLinux_8=ssl1.1, RockyLinux_9.6=ssl3, RockyLinux_9=ssl3.5).
+build:
+ RockyLinux_9: false
+ RockyLinux_9.6: false
diff --git a/root/ppg/common/deps/tarballs/percona-proj/rpm/percona-proj.spec b/root/ppg/common/deps/tarballs/percona-proj96/rpm/percona-proj96.spec
similarity index 85%
rename from root/ppg/common/deps/tarballs/percona-proj/rpm/percona-proj.spec
rename to root/ppg/common/deps/tarballs/percona-proj96/rpm/percona-proj96.spec
index a0d0ec10c..274be0109 100644
--- a/root/ppg/common/deps/tarballs/percona-proj/rpm/percona-proj.spec
+++ b/root/ppg/common/deps/tarballs/percona-proj96/rpm/percona-proj96.spec
@@ -37,16 +37,9 @@
%global proj_prefix /opt/percona-proj
-# PERCONA: base-specific upstream version + which Source to unpack. Both
-# are CMake-only (PROJ dropped autotools in 9.0), so every base takes the
-# same %%build/%%install path below.
-%if 0%{?rhel} == 8
+# PERCONA: one package per tarball base (percona-proj96: RHEL 8,
+# percona-proj98: RHEL 9), each with a single upstream version.
%global proj_version %!{GIS_PROJ_EL8_VERSION}
-%global proj_srcidx 0
-%else
-%global proj_version %!{GIS_PROJ_VERSION}
-%global proj_srcidx 1
-%endif
%global proj_soname 25
# PERCONA: same compiler as proj96/proj98 (PGDG): PROJ 9.6+/9.8 needs
@@ -56,16 +49,13 @@
%global gts_version 14
%endif
-Name: percona-proj
+Name: percona-proj%!{GIS_PROJ_EL8_MAJOR}
Version: %{proj_version}
Release: 1%{?dist}
Summary: PROJ runtime under /opt/percona-proj for the Percona PostgreSQL binary tarball
License: MIT
URL: https://proj.org/
-# PERCONA: both tarballs are always fetched by the _service; the %%prep
-# section unpacks only the one that matches the base being built.
Source0: proj-%!{GIS_PROJ_EL8_VERSION}.tar.gz
-Source1: proj-%!{GIS_PROJ_VERSION}.tar.gz
BuildRequires: gcc
BuildRequires: gcc-c++
@@ -90,16 +80,14 @@ BuildRequires: libcurl-devel
PROJ %{version} built from the upstream source with the install prefix
/opt/percona-proj, so libproj's compiled-in PROJ_DATA default is
/opt/percona-proj/share/proj and proj.db resolves without any
-environment variables. The upstream version is picked per base so the
-SONAME matches the libproj that the shipped PostGIS RPMs linked
-against (RHEL 8: 9.6.2 like proj96, RHEL 9: 9.8.1 like proj98, both
-libproj.so.25), making this a drop-in replacement inside the Percona
-PostgreSQL binary tarball. Consumed by the tarball build; not intended
+environment variables. This is the RHEL 8
+build: its libproj.so.25 matches the libproj of proj96 that the
+shipped PostGIS RPMs link, making it a drop-in replacement inside
+the Percona PostgreSQL binary tarball. Consumed by the tarball build; not intended
for standalone installation.
%prep
-# PERCONA: -T -b %%{proj_srcidx} — unpack only the base-matching tarball.
-%setup -q -T -b %{proj_srcidx} -n proj-%{version}
+%setup -q -n proj-%{version}
%build
%if 0%{?gts_version}
@@ -141,8 +129,8 @@ make -C build install DESTDIR=%{buildroot}
# 1. SONAME parity. The package is only useful as a drop-in for the libproj
# the shipped PostGIS RPMs linked against, so assert the SONAME we
# promised for this base actually came out. Without this, a source-URL
-# bump — or this spec being built on an unexpected %%{?rhel} where the
-# %%if picks the wrong branch — would silently produce a library that is
+# bump — or this package being built on the wrong base — would silently
+# produce a library that is
# no longer ABI-compatible with PostGIS.
test -e %{buildroot}%{proj_prefix}/lib/libproj.so.%{proj_soname}
# 2. The compiled-in data path, and a proj.db sitting at it.
@@ -154,6 +142,11 @@ grep -q '%{proj_prefix}/share/proj' %{buildroot}%{proj_prefix}/lib/libproj.so.%{
%{proj_prefix}
%changelog
+* Tue Oct 20 2026 Percona Development - %{version}-%{release}
+- Split percona-proj into one package per tarball base so each OBS
+ package builds a single version: percona-proj96 (RHEL 8, PROJ 9.6.2)
+ and percona-proj98 (RHEL 9, PROJ 9.8.1). Install prefix unchanged.
+
* Sun Oct 18 2026 Percona Development - %{version}-%{release}
- Follow the PGDG-mirrored PROJ that PostGIS now links: 9.6.2 on RHEL 8
(proj96) and 9.8.1 on RHEL 9 (proj98), both libproj.so.25, versions
diff --git a/root/ppg/common/deps/tarballs/percona-proj98/obs/_service b/root/ppg/common/deps/tarballs/percona-proj98/obs/_service
new file mode 100644
index 000000000..b5384caf4
--- /dev/null
+++ b/root/ppg/common/deps/tarballs/percona-proj98/obs/_service
@@ -0,0 +1,13 @@
+
+
+
+ download.osgeo.org
+ https
+ /proj/proj-%!{GIS_PROJ_VERSION}.tar.gz
+ proj-%!{GIS_PROJ_VERSION}.tar.gz
+
+
diff --git a/root/ppg/common/deps/tarballs/percona-proj98/package.yaml b/root/ppg/common/deps/tarballs/percona-proj98/package.yaml
new file mode 100644
index 000000000..c3106b29f
--- /dev/null
+++ b/root/ppg/common/deps/tarballs/percona-proj98/package.yaml
@@ -0,0 +1,17 @@
+title: /opt-prefixed PROJ runtime for the PPG binary tarball
+description: |
+ PROJ built from upstream source with the install prefix
+ /opt/percona-proj, so libproj's compiled-in PROJ_DATA default is
+ /opt/percona-proj/share/proj and proj.db is found with zero
+ environment variables. Version follows the PGDG-mirrored PROJ that
+ the shipped PostGIS RPMs link (ppg:common:deps:postgis):
+ RHEL 8 -> PROJ 9.6.2 like proj96, RHEL 9 -> PROJ 9.8.1 like proj98,
+ both libproj.so.25. That makes it a drop-in replacement for
+ proj96/proj98's libproj inside the binary tarball only — the shipped
+ PostGIS RPMs keep resolving to proj96/proj98 on user systems.
+
+ This package is the RHEL 9 build (RockyLinux_9.6 / RockyLinux_9,
+ tarballs ssl3 / ssl3.5); percona-proj96 is the RHEL 8 one.
+
+build:
+ RockyLinux_8: false
diff --git a/root/ppg/common/deps/tarballs/percona-proj98/rpm/percona-proj98.spec b/root/ppg/common/deps/tarballs/percona-proj98/rpm/percona-proj98.spec
new file mode 100644
index 000000000..9d111aa65
--- /dev/null
+++ b/root/ppg/common/deps/tarballs/percona-proj98/rpm/percona-proj98.spec
@@ -0,0 +1,166 @@
+# PERCONA PACKAGE for ppg:common:deps:tarballs (RockyLinux_8, RockyLinux_9.6, RockyLinux_9).
+#
+# /opt-prefixed PROJ runtime consumed by the Percona PostgreSQL binary
+# tarball (2026-07 tarball QA round, task 22).
+#
+# Why this exists: the tarball bundles the RPM-built postgis-*.so, which
+# links libproj.so.NN, so the tarball has to carry a libproj. EPEL's
+# libproj has its PROJ_DATA (formerly PROJ_LIB) default compiled to
+# /usr/share/proj, a path that does not exist on the tarball's target
+# hosts, so proj.db is never found and every ST_Transform() fails unless
+# the server is started through an env-exporting wrapper (PROJ_DATA/
+# PROJ_LIB) — and QA proved any wrapper bypass breaks it. This package
+# builds PROJ from source with the prefix /opt/percona-proj, so the
+# compiled-in data path is /opt/percona-proj/share/proj, proj.db sits
+# right there, and reprojection works with ZERO environment variables —
+# the official tarball's mechanism.
+#
+# Version is per base and follows the PGDG-mirrored PROJ that the shipped
+# PostGIS RPMs link on that base (ppg:common:deps:postgis proj96/proj98,
+# root/macros.yaml GIS_PROJ_*). Our library must be a drop-in for that one,
+# because the tarball simply substitutes the bundled file:
+#
+# RHEL 8 (ssl1.1 tarball): PROJ 9.6.2 (proj96) -> libproj.so.25
+# RHEL 9 (ssl3/ssl3.5 tarballs): PROJ 9.8.1 (proj98) -> libproj.so.25
+#
+# We deliberately do NOT filter the auto-generated
+# libproj.so.NN()(64bit) Provides: the ssl chroots that assemble the
+# tarball use a project-config `Prefer:` to let this package satisfy
+# PostGIS's SONAME Requires instead of proj96/proj98. Everything
+# installs under /opt/percona-proj, so nothing shadows a system package
+# on a normal install, and ppg:common:deps is publish=false project-wide.
+#
+# Not to be confused with ppg:common:deps `proj` — that package is a
+# Debian-only distro shadow (a newer PROJ for old Debian bases) built to
+# /usr with the distro name. This one is a differently named, /opt-only
+# tarball runtime and the two never meet in a chroot.
+
+%global proj_prefix /opt/percona-proj
+
+# PERCONA: one package per tarball base (percona-proj96: RHEL 8,
+# percona-proj98: RHEL 9), each with a single upstream version.
+%global proj_version %!{GIS_PROJ_VERSION}
+%global proj_soname 25
+
+# PERCONA: same compiler as proj96/proj98 (PGDG): PROJ 9.6+/9.8 needs
+# gcc-toolset-14 on EL8 and EL9 for its C23 cmake check. RHEL 10 ships
+# gcc 14 natively.
+%if 0%{?rhel} && 0%{?rhel} < 10
+%global gts_version 14
+%endif
+
+Name: percona-proj%!{GIS_PROJ_MAJOR}
+Version: %{proj_version}
+Release: 1%{?dist}
+Summary: PROJ runtime under /opt/percona-proj for the Percona PostgreSQL binary tarball
+License: MIT
+URL: https://proj.org/
+Source0: proj-%!{GIS_PROJ_VERSION}.tar.gz
+
+BuildRequires: gcc
+BuildRequires: gcc-c++
+BuildRequires: make
+%if 0%{?gts_version}
+BuildRequires: gcc-toolset-%{gts_version}-gcc
+BuildRequires: gcc-toolset-%{gts_version}-gcc-c++
+BuildRequires: gcc-toolset-%{gts_version}-annobin-plugin-gcc
+%endif
+BuildRequires: cmake >= 3.16
+BuildRequires: sqlite-devel
+# PERCONA: the sqlite3 CLI builds proj.db from the .sql sources at build
+# time — without it there is no database to find at the compiled path.
+BuildRequires: sqlite
+# TIFF + curl are the (default-on) remote/TIFF grid backends and are what
+# proj96/proj98's libproj.so.25 links too — no extra library lands in the
+# tarball, libtiff and libcurl are bundled for GDAL anyway.
+BuildRequires: libtiff-devel
+BuildRequires: libcurl-devel
+
+%description
+PROJ %{version} built from the upstream source with the install prefix
+/opt/percona-proj, so libproj's compiled-in PROJ_DATA default is
+/opt/percona-proj/share/proj and proj.db resolves without any
+environment variables. This is the RHEL 9
+build: its libproj.so.25 matches the libproj of proj98 that the
+shipped PostGIS RPMs link, making it a drop-in replacement inside
+the Percona PostgreSQL binary tarball. Consumed by the tarball build; not intended
+for standalone installation.
+
+%prep
+%setup -q -n proj-%{version}
+
+%build
+%if 0%{?gts_version}
+source /opt/rh/gcc-toolset-%{gts_version}/enable
+%endif
+# PERCONA: plain cmake, not %%cmake — the distro macro forces
+# /usr + lib64 and we need a self-contained /opt tree.
+# CMAKE_INSTALL_LIBDIR=lib: GNUInstallDirs would pick lib64 on EL, and
+# the tarball builder and percona-gdal (CMAKE_PREFIX_PATH, rpath) expect
+# /lib.
+# EMBED_PROJ_DATA_PATH is upstream's default ON and is the whole point of
+# this package: it bakes -DPROJ_DATA="/share/proj" into libproj.
+# BUILD_TESTING=OFF avoids pulling googletest into the chroot.
+mkdir -p build
+cd build
+cmake .. \
+ -DCMAKE_BUILD_TYPE=Release \
+ -DCMAKE_INSTALL_PREFIX=%{proj_prefix} \
+ -DCMAKE_INSTALL_LIBDIR=lib \
+ -DCMAKE_C_FLAGS="%{optflags}" \
+ -DCMAKE_CXX_FLAGS="%{optflags}" \
+ -DBUILD_SHARED_LIBS=ON \
+ -DBUILD_TESTING=OFF \
+ -DBUILD_EXAMPLES=OFF \
+ -DEMBED_PROJ_DATA_PATH=ON \
+ -DENABLE_TIFF=ON \
+ -DENABLE_CURL=ON \
+ -DNLOHMANN_JSON_ORIGIN=internal
+make %{?_smp_mflags}
+
+%install
+%if 0%{?gts_version}
+source /opt/rh/gcc-toolset-%{gts_version}/enable
+%endif
+make -C build install DESTDIR=%{buildroot}
+
+# PERCONA: hard gates on the two properties the whole package exists for.
+#
+# 1. SONAME parity. The package is only useful as a drop-in for the libproj
+# the shipped PostGIS RPMs linked against, so assert the SONAME we
+# promised for this base actually came out. Without this, a source-URL
+# bump — or this package being built on the wrong base — would silently
+# produce a library that is
+# no longer ABI-compatible with PostGIS.
+test -e %{buildroot}%{proj_prefix}/lib/libproj.so.%{proj_soname}
+# 2. The compiled-in data path, and a proj.db sitting at it.
+test -f %{buildroot}%{proj_prefix}/share/proj/proj.db
+grep -q '%{proj_prefix}/share/proj' %{buildroot}%{proj_prefix}/lib/libproj.so.%{proj_soname}
+
+%files
+%license COPYING
+%{proj_prefix}
+
+%changelog
+* Tue Oct 20 2026 Percona Development - %{version}-%{release}
+- Split percona-proj into one package per tarball base so each OBS
+ package builds a single version: percona-proj96 (RHEL 8, PROJ 9.6.2)
+ and percona-proj98 (RHEL 9, PROJ 9.8.1). Install prefix unchanged.
+
+* Sun Oct 18 2026 Percona Development - %{version}-%{release}
+- Follow the PGDG-mirrored PROJ that PostGIS now links: 9.6.2 on RHEL 8
+ (proj96) and 9.8.1 on RHEL 9 (proj98), both libproj.so.25, versions
+ from root/macros.yaml. RHEL 8 drops the 6.3.2 autotools build for the
+ common CMake path; gcc-toolset-14 on EL8/EL9 as in proj96/proj98.
+
+* Wed Sep 02 2026 Percona Build/Release Team - %{version}-%{release}
+- Drop ExcludeArch aarch64: the binary tarball (ppg:staging:NN:tarballs)
+ now builds for aarch64 too, so this runtime is no longer dead weight
+ on that arch.
+
+* Tue Aug 25 2026 Percona Build/Release Team - %{version}-%{release}
+- Initial /opt/percona-proj runtime for the Percona PostgreSQL binary
+ tarball: PROJ 6.3.2 on RHEL 8 (libproj.so.15) and PROJ 9.6.0 on
+ RHEL 9 (libproj.so.25), both with the PROJ_DATA default compiled to
+ /opt/percona-proj/share/proj so proj.db is found with zero
+ environment variables (tarball QA task 22).
diff --git a/root/ppg/common/deps/tarballs/project.yaml b/root/ppg/common/deps/tarballs/project.yaml
index e5c6b9594..d9444d61b 100644
--- a/root/ppg/common/deps/tarballs/project.yaml
+++ b/root/ppg/common/deps/tarballs/project.yaml
@@ -5,8 +5,10 @@ description: |
PG-version-agnostic, so every PG major's tarball project consumes this
one subproject:
- - /opt-prefixed runtimes bundled into the artifact (percona-perl,
- percona-tcl, percona-python3, percona-gdal, percona-proj): every
+ - /opt-prefixed runtimes bundled into the artifact (percona-perl526 /
+ percona-perl532, percona-tcl, percona-python3, percona-gdal38 /
+ percona-gdal313, percona-proj96 / percona-proj98 — one package per
+ EL base where the version differs): every
path compiled to /opt so the RPM-built PLs/PostGIS resolve them with
zero environment variables.
- EL8-only portability rebuilds whose libraries the ssl1.1 tarball
diff --git a/root/ppg/staging/_shared/percona-postgresql-tarball/obs/build-tarball.sh b/root/ppg/staging/_shared/percona-postgresql-tarball/obs/build-tarball.sh
index 6e4be7971..0b3f54879 100644
--- a/root/ppg/staging/_shared/percona-postgresql-tarball/obs/build-tarball.sh
+++ b/root/ppg/staging/_shared/percona-postgresql-tarball/obs/build-tarball.sh
@@ -92,8 +92,8 @@ done
# postgis-3.so and libgdal carry).
GDAL_LIB=$(ls "$GDAL_PREFIX"/lib/libgdal.so.[0-9]* 2>/dev/null | head -1)
PROJ_LIB=$(ls "$PROJ_PREFIX"/lib/libproj.so.[0-9]* 2>/dev/null | head -1)
-[ -n "$GDAL_LIB" ] || { echo "FATAL: no $GDAL_PREFIX/lib/libgdal.so.* — percona-gdal not installed?" >&2; exit 1; }
-[ -n "$PROJ_LIB" ] || { echo "FATAL: no $PROJ_PREFIX/lib/libproj.so.* — percona-proj not installed?" >&2; exit 1; }
+[ -n "$GDAL_LIB" ] || { echo "FATAL: no $GDAL_PREFIX/lib/libgdal.so.* — percona-gdal38/percona-gdal313 not installed?" >&2; exit 1; }
+[ -n "$PROJ_LIB" ] || { echo "FATAL: no $PROJ_PREFIX/lib/libproj.so.* — percona-proj96/percona-proj98 not installed?" >&2; exit 1; }
for f in "$GDAL_PREFIX/share/gdal/gdalicon.png" "$PROJ_PREFIX/share/proj/proj.db"; do
[ -f "$f" ] || { echo "FATAL: resource file $f missing — percona-gdal/percona-proj data dir not at the compiled path" >&2; exit 1; }
done
@@ -109,8 +109,8 @@ done
# the package or a new provider appears.
#
# Two mechanisms keep it clean:
-# * `Prefer: percona-gdal` / `Prefer: percona-proj` (root/ppg/staging/NN/
-# tarballs/project.yaml, both ssl blocks) win the "have choice" for
+# * `Prefer: percona-gdal` / `Prefer: percona-proj` (root/ppg/staging/NN/
+# tarballs/project.yaml, every ssl block, per EL base) win the "have choice" for
# PostGIS's automatic libgdal.so.NN()(64bit)/libproj.so.NN()(64bit)
# soname Requires;
# * percona-gis-compat (ppg:common:deps:tarballs; a
@@ -134,7 +134,7 @@ stray_gis=$(ls /usr/lib64/libgdal.so.* /usr/lib64/libproj.so.* \
/usr/gdal*/lib*/libgdal.so.* /usr/proj*/lib*/libproj.so.* \
2>/dev/null || true)
if [ -n "$stray_gis" ]; then
- echo "FATAL: a distro/PGDG GDAL/PROJ runtime is installed in the chroot — it must be replaced by percona-gdal/percona-proj (prjconf Prefer: + the percona-gis-compat shim, see the comment above this check)" >&2
+ echo "FATAL: a distro/PGDG GDAL/PROJ runtime is installed in the chroot — it must be replaced by percona-gdal/percona-proj (prjconf Prefer: + the percona-gis-compat shim, see the comment above this check)" >&2
# Diagnostics only — every substitution keeps a `|| true`/fallback so a
# failing rpm query cannot abort the script before `exit 1` below (same
# set -e trap as PY_BIN at the top of this file).
diff --git a/root/ppg/staging/_shared/percona-postgresql-tarball/obs/simpleimage b/root/ppg/staging/_shared/percona-postgresql-tarball/obs/simpleimage
index 9425afaa9..ffcf7ae5c 100644
--- a/root/ppg/staging/_shared/percona-postgresql-tarball/obs/simpleimage
+++ b/root/ppg/staging/_shared/percona-postgresql-tarball/obs/simpleimage
@@ -70,8 +70,13 @@ BuildRequires: percona-pg_gather
# presence in the chroot is deterministic instead of resting on the Prefer:
# choice alone.
BuildRequires: percona-psql
-BuildRequires: percona-gdal
-BuildRequires: percona-proj
+%if 0%{?rhel} == 8
+BuildRequires: percona-gdal%!{GIS_GDAL_EL8_MAJOR}
+BuildRequires: percona-proj%!{GIS_PROJ_EL8_MAJOR}
+%else
+BuildRequires: percona-gdal%!{GIS_GDAL_MAJOR}
+BuildRequires: percona-proj%!{GIS_PROJ_MAJOR}
+%endif
BuildRequires: percona-gis-compat
# Companion tools
BuildRequires: percona-pgbouncer
@@ -94,7 +99,11 @@ BuildRequires: python3-pysyncobj
# are gone; the python3.12 interpreter still reaches the chroot
# transitively (the python3.12-* site-packages packages below require it),
# which is what build-tarball.sh's own ELF-patch helper runs on.
-BuildRequires: percona-perl
+%if 0%{?rhel} == 8
+BuildRequires: percona-perl526
+%else
+BuildRequires: percona-perl532
+%endif
BuildRequires: percona-tcl
BuildRequires: percona-python3
# python3.12-* DEPENDENCY packages are kept: they install patroni's
diff --git a/root/ppg/staging/_shared/tarballs/project.yaml b/root/ppg/staging/_shared/tarballs/project.yaml
index e0946954c..42c4f61d6 100644
--- a/root/ppg/staging/_shared/tarballs/project.yaml
+++ b/root/ppg/staging/_shared/tarballs/project.yaml
@@ -188,8 +188,8 @@ project-config: |
# chain whose FlexiBLAS ELF constructor abort()s on Rocky hosts — and has
# its data directory compiled to /usr//share, a path no tarball
# host has. build-tarball.sh asserts they are absent from the chroot.
- Prefer: percona-gdal
- Prefer: percona-proj
+ Prefer: percona-gdal%!{GIS_GDAL_EL8_MAJOR}
+ Prefer: percona-proj%!{GIS_PROJ_EL8_MAJOR}
# ...but `Prefer:` only breaks TIES between providers of the SAME symbol.
# PostGIS also requires the PGDG-mirrored GDAL/PROJ *by name* (rpmspec -q
# --requires on
@@ -259,8 +259,8 @@ project-config: |
# See the ssl1.1 block: our lean /opt GDAL+PROJ must win the
# libgdal.so.NN()(64bit)/libproj.so.NN()(64bit) choice over
# gdal313-libs/proj98.
- Prefer: percona-gdal
- Prefer: percona-proj
+ Prefer: percona-gdal%!{GIS_GDAL_MAJOR}
+ Prefer: percona-proj%!{GIS_PROJ_MAJOR}
# ...but `Prefer:` only breaks TIES between providers of the SAME symbol.
# PostGIS also requires the PGDG-mirrored GDAL/PROJ *by name* (rpmspec -q
# --requires on
@@ -320,8 +320,8 @@ project-config: |
# built the pre-9.6 ssl3 without them. Add back with evidence if the
# first build reports a have-choice.
Prefer: hdf-libs
- Prefer: percona-gdal
- Prefer: percona-proj
+ Prefer: percona-gdal%!{GIS_GDAL_MAJOR}
+ Prefer: percona-proj%!{GIS_PROJ_MAJOR}
Prefer: percona-gis-compat
Prefer: glibc-minimal-langpack
%endif