Fwd: LFS Script suggestion

Bruce Dubbs bruce.dubbs at gmail.com
Mon Jan 29 20:38:24 PST 2007


Ismael Luceno wrote:

> This string depends on the locale in use when the kernel was compiled,
> so it will not work on all systems, it needs to be more generic:
> 
> $ cat /proc/version
> Linux version 2.6.19.1 (ismaell at localhost) (gcc versión 4.0.3) #1 Fri
> Dec 15 02:19:26 UYT 2006
> 
> $ sed -r 's/.*\((gcc .+ [01234567890\.]+)\).*/\1/' /proc/version
> gcc versión 4.0.3

Ismael, that doesn't work for me:

$ sed -r 's/.*\((gcc .+ [01234567890\.]+)\).*/\1/' /proc/version
Linux version 2.6.9-42.0.3.EL_lustre.1.5.97smp (ltest at scsi1)
(gcc version 3.4.4 20050721 (Red Hat 3.4.4-2)) #1 SMP Fri Jan
12 17:22:43 MST 2007

(My line breaks).

  -- Bruce




More information about the lfs-dev mailing list