diskimage-create.sh: try harder with provides in rpm check
When checking whether a package is installed using rpm, try harder using the wanted name as provides of a real package. This fixes the check for installed python-argparse on CentOS 7, as it is provided by the main python package. Thanks to: Brandon James. Closes-Bug: #1494790 Change-Id: I88d1d0293e3dde9c6087e6e0209f234e922f52ce
This commit is contained in:
parent
bd64337f9d
commit
b8aca4e3f8
@ -301,7 +301,9 @@ is_installed() {
|
||||
dpkg -s "$1" &> /dev/null
|
||||
else
|
||||
# centos, fedora, opensuse, or rhel
|
||||
rpm -q "$1" &> /dev/null
|
||||
if ! rpm -q "$1" &> /dev/null; then
|
||||
rpm -q "$(rpm -q --whatprovides "$1")"
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user