From 2956e5e156a2d69451d78deb9f553bae674eae59 Mon Sep 17 00:00:00 2001 From: Andrew Bauer Date: Sun, 5 Jan 2020 14:30:33 -0600 Subject: [PATCH] use dnf rather than yum for newer redhat distros --- utils/packpack/startpackpack.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/utils/packpack/startpackpack.sh b/utils/packpack/startpackpack.sh index 4af3cc161..6a51e2995 100755 --- a/utils/packpack/startpackpack.sh +++ b/utils/packpack/startpackpack.sh @@ -9,7 +9,7 @@ # General sanity checks checksanity () { # Check to see if this script has access to all the commands it needs - for CMD in set echo curl git ln mkdir rmdir cat patch; do + for CMD in set echo curl git ln mkdir rmdir cat patch sed; do type $CMD 2>&1 > /dev/null if [ $? -ne 0 ]; then @@ -298,6 +298,11 @@ if [ "${OS}" == "el" ] || [ "${OS}" == "fedora" ]; then commonprep echo "Begin Redhat build..." + # Newer Redhat distros use dnf package manager rather than yum + if [ "${DIST}" -gt "7" ]; then + sed -i 's\yum\dnf\' utils/packpack/redhat_package.mk + fi + setrpmpkgname ln -sfT distros/redhat rpm