Fix return value from dkms postinst in spec file

This commit is contained in:
Christoffer Sandberg 2020-03-18 10:32:59 +01:00
parent 08f2d80ce1
commit 95723a9555

View file

@ -65,8 +65,9 @@ rm -rf %{buildroot}
for POSTINST in /usr/lib/dkms/common.postinst /usr/share/%{module}/postinst; do for POSTINST in /usr/lib/dkms/common.postinst /usr/share/%{module}/postinst; do
if [ -f $POSTINST ]; then if [ -f $POSTINST ]; then
$POSTINST %{module} %{version} /usr/share/%{module} $POSTINST %{module} %{version} /usr/share/%{module}
RET=$?
modprobe %{module} > /dev/null 2>&1 || true modprobe %{module} > /dev/null 2>&1 || true
exit $? exit $RET
fi fi
echo "WARNING: $POSTINST does not exist." echo "WARNING: $POSTINST does not exist."
done done