From da33032ff77f6cd52494b3bda25ad060e56ab500 Mon Sep 17 00:00:00 2001 From: John Mulligan Date: Tue, 15 Apr 2025 16:03:07 -0400 Subject: [PATCH 1/2] extras: allow a vendor dist suffix field in the spec file Signed-off-by: John Mulligan --- extras/python-sambacc.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extras/python-sambacc.spec b/extras/python-sambacc.spec index ad8a5e0d..0688ae58 100644 --- a/extras/python-sambacc.spec +++ b/extras/python-sambacc.spec @@ -9,7 +9,7 @@ Name: python-%{bname} Version: %{rversion} -Release: 1%{?dist} +Release: 1%{?dist}%{?vendordist} Summary: Samba Container Configurator License: GPLv3+ From 1c4cc0ea1a80056af6f66732d2c7264d2b11fbd0 Mon Sep 17 00:00:00 2001 From: John Mulligan Date: Tue, 15 Apr 2025 16:04:04 -0400 Subject: [PATCH 2/2] tests/container: set a vendor suffix with VENDOR_DIST_SUFFIX If the shell script is run with the VENDOR_DIST_SUFFIX env var set to a value, it will pass that along to the rpm build as the vendordist value to be suffixed to the release ver. Signed-off-by: John Mulligan --- tests/container/build.sh | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/tests/container/build.sh b/tests/container/build.sh index f03482b0..ddf3f0ce 100755 --- a/tests/container/build.sh +++ b/tests/container/build.sh @@ -198,11 +198,15 @@ task_rpm_build() { tar -xf "$spkg" -O \ "sambacc-${ver}/extras/python-sambacc.spec" ) > "${tdir}/python-sambacc.spec" - rpmbuild "${rpmbuild_stage}" \ + rpmbuild_cmd=(rpmbuild "${rpmbuild_stage}" \ -D "_rpmdir ${distdir}/RPMS" \ -D "_srcrpmdir ${distdir}/SRPMS" \ -D "_sourcedir $(dirname "${spkg}")" \ - "${tdir}/python-sambacc.spec" + ) + if [ "$VENDOR_DIST_SUFFIX" ]; then + rpmbuild_cmd+=(-D "vendordist ${VENDOR_DIST_SUFFIX}") + fi + "${rpmbuild_cmd[@]}" "${tdir}/python-sambacc.spec" rm -rf "${tdir}" done }