> Perhaps using uname would be a better way to
> distinguish the releases? This is in machine-readable
> format, from what I understand...

Yes, however:

a) usable with switches only when one has one UNIX, and nothing else (100% 
platform consolidation), which is unlikely

or

b) in case of a heterogenous UNIX environment, only uname(1) alone, without any 
switches, can be used in a sane manner.

The fundamental problem is that uname(1) switches and output, except for 
calling uname(1) by itself, are inconsistent among different flavors of UNIX, 
even System V UNIX. While the output is machine parsable, it is not guaranteed, 
and it is not the case, that a switch for uname(1) which exists on Solaris will 
exist on HP-UX, or FreeBSD, or ..., and even further, it's not at all the case, 
that those switches will deliver the same information.

So something like this will work reliably:

/export/install/`uname`/:

/export/install/SunOS/
/export/install/HP-UX/
/export/install/IRIX/

but something like this has no chance of working in any consistent way:

/export/install/`uname -p`/
/export/install/`uname -m`/
/export/install/`uname -r`/
/export/install/`uname -X`/
-- 
This message posted from opensolaris.org
_______________________________________________
opensolaris-discuss mailing list
[email protected]

Reply via email to