FW: [Bug 221079] New: CLEAN trumped if no MAKE* exists in dkms.conf
Matt Domsch
Matt_Domsch at dell.com
Tue Jan 2 17:29:47 CST 2007
On Mon, Jan 01, 2007 at 10:18:33AM -0600, Matt_Domsch at dell.com wrote:
> Subject: [Bug 221079] New: CLEAN trumped if no MAKE* exists in dkms.conf
> https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=221079
>
> Specified CLEAN=... in dkms.conf is trumped by built-in defaults if no
> MAKE* exists in dkms.conf.
>
> A quick (untested) patch attached, along with some spelling fixes for
> the man page.
You've got to turn the logic around, version test first, then test for
existance of $make_command and $clean and set them if not set.
Otherwise you're still stuck with $clean not set if $make_command
was set. Something like:
--- dkms-2.0.13.driverdisks Tue Jan 2 17:15:26 2007
+++ dkms Tue Jan 2 17:24:59 2007
@@ -431,13 +431,19 @@ function read_conf ()
index=$(($index+1))
done
- # Use the generic make command if no make command has been specified
- if [ -z "$make_command" ]; then
- if [[ $(VER $1) < $(VER 2.6.6) ]]; then
+ # Use the generic make and make clean commands if not specified
+ if [[ $(VER $1) < $(VER 2.6.6) ]]; then
+ if [ -z "$make_command" ]; then
make_command="make -C $kernel_source_dir SUBDIRS=$dkms_tree/$module/$module_version/build modules"
+ fi
+ if [ -z "$clean" ]; then
clean="make -C $kernel_source_dir SUBDIRS=$dkms_tree/$module/$module_version/build clean"
- else
+ fi
+ else
+ if [ -z "$make_command" ]; then
make_command="make -C $kernel_source_dir M=$dkms_tree/$module/$module_version/build"
+ fi
+ if [ -z "$clean" ]; then
clean="make -C $kernel_source_dir M=$dkms_tree/$module/$module_version/build clean"
fi
fi
I'll take the spelling fixes. Thanks for the report and the patch!
-Matt
--
Matt Domsch
Software Architect
Dell Linux Solutions linux.dell.com & www.dell.com/linux
Linux on Dell mailing lists @ http://lists.us.dell.com
More information about the DKMS-devel
mailing list