diff options
author | V3n3RiX <venerix@rogentos.ro> | 2016-10-23 13:21:14 +0100 |
---|---|---|
committer | V3n3RiX <venerix@rogentos.ro> | 2016-10-23 13:21:14 +0100 |
commit | 655ac74f6d1dca3fd56c92fe4d42c35b10b74f31 (patch) | |
tree | b05aaec4971d2d6761005e770cee0e34b6828cdd /sys-kernel/dkms/files/dkms-2.2.0.3-dont-touch-configs.patch | |
parent | 1ee72da9a68ba8dc94bf31566ee45cb3dcb3b53b (diff) |
dkms : don't touch config files, use gentoo-functions, add systemd service
Diffstat (limited to 'sys-kernel/dkms/files/dkms-2.2.0.3-dont-touch-configs.patch')
-rw-r--r-- | sys-kernel/dkms/files/dkms-2.2.0.3-dont-touch-configs.patch | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/sys-kernel/dkms/files/dkms-2.2.0.3-dont-touch-configs.patch b/sys-kernel/dkms/files/dkms-2.2.0.3-dont-touch-configs.patch new file mode 100644 index 00000000..9d2dcbe6 --- /dev/null +++ b/sys-kernel/dkms/files/dkms-2.2.0.3-dont-touch-configs.patch @@ -0,0 +1,26 @@ +diff -Nur a/dkms b/dkms +--- a/dkms 2011-12-07 18:23:58.000000000 +0000 ++++ b/dkms 2016-10-23 12:35:35.863843825 +0100 +@@ -756,22 +756,6 @@ + sa_sck_o[${#sa_sck_o[@]}]="s/\(INITRD_MODULES.*\)$obsolete_module\b\(.*\)/\1${dest_module_name[$index]}\2/" + done + done +- +- # do all the changes at once, record the diffs for posterity +- for file in "$@"; do +- [[ $file && -w $file ]] || continue +- if [[ $file = /etc/sysconfig/kernel ]]; then +- sed "${sa_sck_o[@]}" "$file" > "$temp_dir_name/${file##*/}.new" +- else +- sed "${sa_mc_o[@]}" "$file" > "$temp_dir_name/${file##*/}.new" +- fi +- if ! mod_diff=$(diff -u "$temp_dir_name/${file##*/}.new" "$file"); then +- echo $"$file updated to replace obsoleted module references:" +- echo "$mod_diff" +- cp -fp "$temp_dir_name/${file##*/}.new" "$file" +- rm -f "$temp_dir_name/${file##*/}.new" +- fi +- done + } + + moduleconfig_add() |