Skip to content

Commit

Permalink
Merge pull request #20 from yuzaipiaofei/master
Browse files Browse the repository at this point in the history
FIX dkms built issues for rhel kernel update ,change prerm script to …
  • Loading branch information
Perry.Yuan authored Mar 13, 2017
2 parents 86b7f68 + b8c4750 commit 974d838
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
4 changes: 3 additions & 1 deletion dkms
Original file line number Diff line number Diff line change
Expand Up @@ -1730,7 +1730,9 @@ do_uninstall()
fi
fi
done
rm -f "$dkms_tree/$module/kernel-$1-$2"
rm -rf "$dkms_tree/$module/kernel-$1-$2"
#Remove modules from dkms built tree
rm -rf "$dkms_tree/$module/$module_version/$1"
else
echo $""
echo $"Status: This module version was INACTIVE for this kernel."
Expand Down
2 changes: 1 addition & 1 deletion dkms.spec
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ rm -rf $RPM_BUILD_ROOT
%if 0%{?fedora} >= 20 || 0%{?rhel} >= 7 || 0%{?suse_version} >= 1210

%post
%systemd_post %{name}.service
systemctl enable %{name}.service>/dev/null 2>&1

%preun
if [ $1 -eq 0 ]; then
Expand Down
2 changes: 1 addition & 1 deletion kernel_prerm.d_dkms
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ while read line; do
vers=`echo "$line" | awk '{print $2}' | sed 's/,$//'`
arch=`echo "$line" | awk '{print $4}' | sed 's/:$//'`
echo "dkms: removing: $name $vers ($inst_kern) ($arch)" >&2
dkms remove -m $name -v $vers -k $inst_kern -a $arch
dkms uninstall -m $name -v $vers -k $inst_kern -a $arch
done < <(dkms status -k $inst_kern 2>/dev/null | grep ": installed")
fi

Expand Down

0 comments on commit 974d838

Please sign in to comment.