diff --git a/diskimage-create/diskimage-create.sh b/diskimage-create/diskimage-create.sh index c6c5b62217..9f0e52964c 100755 --- a/diskimage-create/diskimage-create.sh +++ b/diskimage-create/diskimage-create.sh @@ -314,10 +314,9 @@ else # fedora/centos/rhel # Actual qemu-img name may be qemu-img, qemu-img-ev, qemu-img-rhev, ... # "dnf|yum install qemu-img" works for all, but search requires wildcard - PKG_MGR=$(which dnf &>/dev/null && echo dnf || echo yum) PKG_LIST="qemu-img* git" for pkg in $PKG_LIST; do - if ! $PKG_MGR info installed $pkg &> /dev/null; then + if ! rpm -qa $pkg ; then echo "Required package " ${pkg/\*} " is not installed. Exiting." exit 1 fi