From 9aa9ebe7026c9547e26c1792791fa1c04742102d Mon Sep 17 00:00:00 2001 From: Trevor Batley Date: Mon, 6 Nov 2023 20:23:40 +1100 Subject: [PATCH] add in rpm macro settings --- koji-setup/koji-bootstrap-build.sh | 23 +++++++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) diff --git a/koji-setup/koji-bootstrap-build.sh b/koji-setup/koji-bootstrap-build.sh index e9645bc..e7643c3 100755 --- a/koji-setup/koji-bootstrap-build.sh +++ b/koji-setup/koji-bootstrap-build.sh @@ -58,9 +58,14 @@ if [[ -n "$SRC_RPM_DIR" && -n "$BIN_RPM_DIR" ]]; then rm -rf "$STAGING_RPM_DIR" "$HOME/.koji" fi +# Generic settings for smeserver +PACKAGER="Koozali.org " +VENDOR="Koozali.org " # Setup sme10 for building # sme10-os is the parent - all other sme10 repos will inherit most of this... RELEASE=10 +DISTRIBUTION="SME Server v$RELEASE" +DIST= ".el7.sme" PKGMANAGER="yum" BOOTSTRAPIMAGE="centos:7" CHROOTSETUPCMD=' install @buildsys-build @buildsys scl-utils-build python27-build rpm-build ' @@ -71,6 +76,10 @@ sudo -u kojiadmin koji add-tag --parent dist-"$TAG" --arches "$RPM_ARCH" dist-"$ sudo -u kojiadmin koji add-target dist-"$TAG" dist-"$TAG"-build sudo -u kojiadmin koji edit-tag dist-"$TAG" -x mock.bootstrap_image="$BOOTSTRAPIMAGE" sudo -u kojiadmin koji edit-tag dist-"$TAG" -x mock.chroot_setup_cmd="$CHROOTSETUPCMD" +sudo -u kojiadmin koji edit-tag dist-"$TAG" -x rpm.macro.distribution=$DISTRIBUTION +sudo -u kojiadmin koji edit-tag dist-"$TAG" -x rpm.macro.packager=$PACKAGER +sudo -u kojiadmin koji edit-tag dist-"$TAG" -x rpm.macro.vendor=$VENDOR +sudo -u kojiadmin koji edit-tag dist-"$TAG" -x rpm.macro.dist=$DIST sudo -u kojiadmin koji add-group dist-"$TAG"-build build sudo -u kojiadmin koji add-group dist-"$TAG"-build srpm-build sudo -u kojiadmin koji add-group-pkg dist-"$TAG"-build build install @buildsys-build @buildsys scl-utils-build python27-build rpm-build @@ -111,11 +120,12 @@ for REPO in addons updates updates-testing testing ; do sudo -u kojiadmin koji add-tag --parent dist-sme$RELEASE-os dist-"$TAG" done -# Releases sme11 and sme12 are based on Rocky 8 -PKGMANAGER="dnf" -BOOTSTRAPIMAGE="rockylinux:8" +# Releases sme11 and sme12 are based on Rocky 8 (EL8) EL="8" -CHROOTSETUPCMD=' install epel-rpm-macros bash bzip2 coreutils cpio diffutils findutils gawk gcc gcc-c++ grep gzip info make patch redhat-rpm-config rpmbuild sed shadow-utils tar unzip util-linux which xz ' +DIST= ".el$EL.sme" +PKGMANAGER="dnf" +BOOTSTRAPIMAGE="rockylinux:$EL" +CHROOTSETUPCMD=' install epel-rpm-macros bash bzip2 coreutils cpio diffutils findutils gawk gcc gcc-c++ grep gzip info make patch redhat-rpm-config rpmbuild sed shadow-utils tar unzip util-linux which yum-utils xz ' sudo -u kojiadmin koji add-external-repo os$EL https://dl.rockylinux.org/pub/rocky/$EL/BaseOS/x86_64/os/ # mirrorList=http://mirrors.rockylinux.org/mirrorlist?release=$EL&arch=x86_64&repo=BaseOS-$EL sudo -u kojiadmin koji add-external-repo appstream$EL https://dl.rockylinux.org/pub/rocky/$EL/AppStream/x86_64/os/ @@ -128,6 +138,7 @@ sudo -u kojiadmin koji add-external-repo openfusion$EL http://repo.openfusion.ne sudo -u kojiadmin koji add-external-repo rpmfusion$EL http://download1.rpmfusion.org/free/el/updates/$EL/x86_64 for RELEASE in 11 12 ; do # Setup the os repo - parent of others who will inherit most properties + DISTRIBUTION="SME Server v$RELEASE" TAG="sme$RELEASE-os" sudo -u kojiadmin koji add-tag dist-"$TAG" sudo -u kojiadmin koji edit-tag dist-"$TAG" -x mock.package_manager=$PKGMANAGER @@ -137,6 +148,10 @@ for RELEASE in 11 12 ; do sudo -u kojiadmin koji add-group dist-"$TAG"-build srpm-build sudo -u kojiadmin koji edit-tag dist-"$TAG" -x mock.bootstrap_image="$BOOTSTRAPIMAGE" sudo -u kojiadmin koji edit-tag dist-"$TAG" -x mock.chroot_setup_cmd="$CHROOTSETUPCMD" + sudo -u kojiadmin koji edit-tag dist-"$TAG" -x rpm.macro.distribution=$DISTRIBUTION + sudo -u kojiadmin koji edit-tag dist-"$TAG" -x rpm.macro.packager=$PACKAGER + sudo -u kojiadmin koji edit-tag dist-"$TAG" -x rpm.macro.vendor=$VENDOR + sudo -u kojiadmin koji edit-tag dist-"$TAG" -x rpm.macro.dist=$DIST sudo -u kojiadmin koji add-group-pkg dist-"$TAG"-build build epel-rpm-macros bash bzip2 coreutils cpio diffutils findutils gawk gcc gcc-c++ grep gzip info make patch redhat-rpm-config rpmbuild sed shadow-utils tar unzip util-linux which yum-utils xz sudo -u kojiadmin koji add-group-pkg dist-"$TAG"-build srpm-build coreutils cpio curl-bin elfutils file git glibc-utils grep gzip make pigz plzip rpm rpmbuild sed shadow tar unzip wget xz sudo -u kojiadmin koji add-external-repo -t dist-"$TAG"-build os$EL