[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[linrad] Re: Build trouble
- Subject: [linrad] Re: Build trouble
- From: Leif Asbrink <sm5bsz.com; leif@xxxxxxxxxxxxxxxx>
- Date: Sat, 13 May 2006 01:53:56 +0200
Hi Chris and all,
> > kernver.c is a stupid fix to a trivial problem. I am sure there
> > is a proper way to do it, but I have not been able to figure
> > out how to determine the version number for the kernel to
> > have it available at compile time.
>
> Would something like this in a bash script help?
>
> if test X"`uname -sr | cut -d. -f-2`" = X"Linux 2.4"; then
> ...
YES:-)
After quite some time I arrived at this:
kernver=`(uname -sr) | cut -d. -f-2`
if test "$kernver" = "Linux 2.2"; then
.......
else
if test "$kernver" = "Linux 2.4"; then
.....
else
......
fi
fi
The file kernver.c is no longer present in the
Linrad package:-)
Many thanks Chris.
The console command uname -sr | cut -d. -f-2
gives exactly what I want to test against but it
was not so easy to figure out how to test the
output from this command against the different
version strings;-)
73
Leif
#############################################################
This message is sent to you because you are subscribed to
the mailing list <linrad@xxxxxxxxxxxxxxxxxxxxx>.
To unsubscribe, E-mail to: <linrad-off@xxxxxxxxxxxxxxxxxxxxx>
To switch to the DIGEST mode, E-mail to <linrad-digest@xxxxxxxxxxxxxxxxxxxxx>
To switch to the INDEX mode, E-mail to <linrad-index@xxxxxxxxxxxxxxxxxxxxx>
Send administrative queries to <linrad-request@xxxxxxxxxxxxxxxxxxxxx>
LINRADDARNIL