Install external package builders on demand

If they are not in already enabled repositories, test dependency would
not be enough.
This commit is contained in:
Petr Menšík 2024-07-31 21:25:34 +02:00 committed by psklenar
commit 27bd4c448c
2 changed files with 6 additions and 5 deletions

View file

@ -5,5 +5,3 @@ require:
- bind-devel
recommend:
- fedpkg
- centpkg
- rhpkg

View file

@ -8,21 +8,24 @@ rlJournalStart
rlRun "tmp=\$(mktemp -d)" 0 "Create tmp directory"
rlRun "pushd $tmp"
rlRun "source /etc/os-release"
case "$ID"
case "$ID" in
centos)
PKG=centpkg
BRANCH=cs${VERSION}
rlRun "rpm -q $PKG || dnf install -y --enablerepo=epel $PKG"
;;
rhel)
PKG=rhpkg
BRANCH=rhel-${VERSION}-main
rlRun "rpm -q $PKG || dnf install -y --enablerepo='*CRB' --enablerepo='*buildroot' $PKG"
;;
fedora)
PKG=fedpkg
BRANCH=rawhide
rlRun "rpm -q $PKG || dnf install -y $PKG"
;;
*)
rlFatal "Unsupported distribution $ID" ;;
rlLogFatal "Unsupported distribution $ID" ;;
esac
rlRun "$PKG clone -a bind-dyndb-ldap"
rlRun "pushd bind-dyndb-ldap"
@ -31,7 +34,7 @@ rlJournalStart
rlPhaseStartTest
rlRun "git checkout $BRANCH"
rlRun "$PKG local"
rlRun "rpm -qpl $(arch)/bind-dyndb-ldap-*.$(arch).rpm"
rlRun "rpm -qpl $(arch)/bind-dyndb-ldap-*.$(arch).rpm | grep bind/ldap.so"
rlPhaseEnd
rlPhaseStartCleanup