From 9c6cb5d965387ba7254aa7baf2b1be9ab439a0b2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20Posp=C3=AD=C5=A1il?= Date: Thu, 28 Aug 2025 00:00:54 +0200 Subject: [PATCH] ensure compatibility with rpm before and after 4.20 When backporting the gating changes in Fedora, I found out that they are not backwards compatible with odl RPM. While I could just roll back the incomptabile changes as I did in that older Fedora branch, I'm not going to do that. Because this branch is supposed to be upstream of the eln brnach with Fedora that includes the new RPM version, this should make the testing run both with older and newer RPM versions. --- tests/prepare-tests.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/prepare-tests.sh b/tests/prepare-tests.sh index bdf43e2..69d8976 100755 --- a/tests/prepare-tests.sh +++ b/tests/prepare-tests.sh @@ -4,6 +4,9 @@ set -eo xtrace cd $TMT_SOURCE_DIR # Use stamp file to abort if this script already ran if [ -e tests-prepared-stamp ]; then exit 0; fi +# tmt patched the sources with rpmbuild, but RPM<4.20 still leaves the SPECPARTS +# folder, remove it +rm -rfv *SPECPARTS # RPM 4.20 changed the builddir structure - unpacked sources go to *-build but # tmt copies them back to pcs-*, so the pcs-*-build folder is empty # Remove pcs-web-ui, pcs-*-build for "cd pcs-*" to have exactly one match @@ -12,8 +15,6 @@ cd pcs-*/ # Run autotools, use bundled dependencies from the system export PYTHONPATH=/usr/lib/pcs/pcs_bundled/packages/ export GEM_HOME=/usr/lib/pcsd/vendor/bundle/ -# We need to use cd pcs-* because when pcs-web-ui starts using autotools, running -# autogen and configure with expanded TMT_SOURCE_DIR will match that too ./autogen.sh ./configure --enable-local-build --enable-use-local-cache-only \ --enable-individual-bundling --enable-webui --with-pcs-lib-dir=/usr/lib