Configure scripts

David Kramer david at kramer.ne.mediaone.net
Sat May 22 21:30:50 EDT 1999


Jerry Feldman wrote:
> 
> I am looking for a distribution independent method to definitively determine
> that I am running on a linux host. The way that the current scrips are
> configured is:
> test -f /boot/vmlinuz
> 
> I don't like this because Alpha linux is /vmlinux.gz
> 
> uname returns Linux.
> I test this on SuSE today, but I would surmise that uname is the best way
> to go. Any thoughts.

Red Hat reports the same thing.  IMHO, I would use uname because it is
the sole function of uname -s to tell you the name of the operating
system.  It's sort of like using the published, external API to a
library instead of calling the lower-level functions which may change in
a later version (Like StarOffice).  I would, however, do a
case-insensitive comparison ty CYA.
-------------------------------------------------------------------
DDDD   David Kramer                    david at kramer.ne.mediaone.net
DK KD                                  http://start.at/david.kramer
DKK D  
DK KD  It is harder to conceal ignorance than to acquire knowledge.
DDDD
-
Subcription/unsubscription/info requests: send e-mail with
"subscribe", "unsubscribe", or "info" on the first line of the
message body to discuss-request at blu.org (Subject line is ignored).



More information about the Discuss mailing list