[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#241395: libc6: preinst fails for kernel 2.4.23dual



At 03 Apr 2004 00:39:01 +0200,
Goswin von Brederlow wrote:
> > There are various ways to fix this situation, one example:
> > 
> > 	kernel_rev=$(uname -r | awk -F '[.-]' '{print $3}' | sed 's/\([[:digit:]]*\).*/\1/' )
> 
> kernel_rev=$(uname -r | sed 's/\([0-9]*\.[0-9]*\.\)\([0-9]*\)\(.*\)/\2/')
> 
> Please don't use awk (see BTS for related bugs). awk requires a
> Pre-Depends since its an alternative and mawk (provides awk) is not
> even essential.
> 
> sed on the other hand is essential.

Thanks for your code, but I've put my version.

Using awk is no problem.  At least it uses in libc.postinst,
locales.config.  But the reason I've put my version is that it seems
more robust for much crazy kernel version for example 2.4.-test1 and
so on.

Regards,
-- gotom





Reply to: