Hello,

AFAIK, modconf does not yet work with 2.6 kernels (with .ko suffix for
kernel module filename) well, so i've attempted to patch it.
The lame results of that attempt  *should* be attached to this mail
(buggy evolution doesn't show me attachments i'm sending) :).

Generally, i've simply grepped for ".o" and changed it to a variable
which has a value of ".o" or ".ko" depending on the kernel version.

Don't know if that's a side effect of my patch or not, but somewhy i no
longer see some captions for categories. ;]

i hope this patch (or this patch patched again) will be included in the
upcoming versions of modconf, so that people don't get scared as i was,
when they try 2.6 for a first time.

Finally, i'm not subscribed to this list, so, please, CC: all the
answers (if any) to this post to me. Thanks.

regards,
Rimas "RQ" Kudelis
11a12,21
> # do we need ".o" or ".ko" as a suffix for kernel module filenames?
> # (will only work with versions lower, than 10.0 =], and i'm unsure about 2.5)
> if ((`uname -r |cut -c1,3` >= 26)); then
>    Ko_Suffix="ko";
> else
>    Ko_Suffix="o";
> fi;
> 
> echo "Using \".$Ko_Suffix\" as an extention for kernel objects.";
> 
214c224
<       -f $(first $Dir_Prefix/$i/*.o) ]; then
---
>       -f $(first $Dir_Prefix/$i/*.$Ko_Suffix) ]; then
34,35c34,35
<   # strip off .o suffix
<   module=${module%.o}
---
>   # strip off .o/.ko suffix
>   module=${module%.$Ko_Suffix}
60c60
<     chandev_module_list="$(for file in `find /lib/modules/$kver -name "*.o"`; do grep -q "chandev_register" $file;  if [ $? -eq 0 ]; then basemodulename $file; fi; done | sort -u)"
---
>     chandev_module_list="$(for file in `find /lib/modules/$kver -name "*.$Ko_Suffix"`; do grep -q "chandev_register" $file;  if [ $? -eq 0 ]; then basemodulename $file; fi; done | sort -u)"
133c133
<     list="$Dir_Prefix/$directory/*.o"
---
>     list="$Dir_Prefix/$directory/*.$Ko_Suffix"
137c137
<     # Strip directory and .o suffix
---
>     # Strip directory and .o/.ko suffix
196c196
<           result=$(basemodulename $Dir_Prefix/$directory/$result.o)
---
>           result=$(basemodulename $Dir_Prefix/$directory/$result.$Ko_Suffix)
340,341c340,341
<     (cd /; zcat < /floppy/modules.tgz | $extract \*/$module.o)
<     file="/lib/modules/*/*/$module.o"
---
>     (cd /; zcat < /floppy/modules.tgz | $extract \*/$module.$Ko_Suffix)
>     file="/lib/modules/*/*/$module.$Ko_Suffix"

Attachment: pgp00000.pgp
Description: PGP signature



Reply via email to