106
106
if (! -e "$tmp/etc/modprobe.d") {
107
107
doit("install","-d","$tmp/etc/modprobe.d");
109
doit("install","-m","0644",$modprobe_file,"$tmp/etc/modprobe.d/".pkgfilename($package).".conf");
109
my $old="/etc/modprobe.d/".pkgfilename($package);
110
my $new=$old.".conf";
111
doit("install","-m","0644",$modprobe_file,"$tmp/$new");
112
autoscript($package,"preinst","preinst-moveconffile","s!#OLD#!$old!g;s!#PACKAGE#!$package!g");
113
autoscript($package,"postinst","postinst-moveconffile","s!#OLD#!$old!g;s!#NEW#!$new!g");
112
116
if (! $dh{NOSCRIPTS}) {
113
my $old="/etc/modprobe.d/".pkgfilename($package);
114
my $new="/etc/modprobe.d/".pkgfilename($package).".conf";
116
autoscript($package,"preinst","preinst-modules-preserve","s!#OLD#!$old!g;s!#NEW#!$new!g;s!#PACKAGE#!$package!g");
117
autoscript($package,"postinst","postinst-modules-preserve","s!#OLD#!$old!g;s!#NEW#!$new!g;s!#PACKAGE#!$package!g");
119
117
foreach my $kvers (find_kernel_modules("$tmp/lib/modules")) {
120
118
autoscript($package,"postinst","postinst-modules","s/#KVERS#/$kvers/g");
121
119
autoscript($package,"postrm","postrm-modules","s/#KVERS#/$kvers/g");