delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/1999/09/12/18:20:54

From: Alain Magloire <alainm AT rcsm DOT ece DOT mcgill DOT ca>
Message-Id: <199909122215.SAA27455@mccoy2.ECE.McGill.CA>
Subject: Re: CPU identification (Was: Re: uname -m ?)
To: djgpp-workers AT delorie DOT com
Date: Sun, 12 Sep 1999 18:15:24 -0400 (EDT)
In-Reply-To: <199909122033.PAA26720@darwin.sfbr.org> from "Jeff Williams" at Sep 12, 99 03:33:33 pm
X-Mailer: ELM [version 2.4 PL25]
MIME-Version: 1.0
Reply-To: djgpp-workers AT delorie DOT com
X-Mailing-List: djgpp-workers AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

Bonjour

> -: > I actually think it is a good idea to add this extension via
> -: > a new switch for example '-x' or -f etc .. and a new member name
> -: > to utsname.
> -: 
> -: Switches for `uname' program is something that should be suggested to
> -: Jim Meyering, the maintainer of Sh-utils.  Unlike Sun, we don't have
> -: our own version of `uname'.

I don't know if GNU/Linux is using sh-utils or some extended fork version
but when login :

$ uname -rs
Linux 2.0.36
$ uname --help
Usage: uname [OPTION]...
Print certain system information.  With no OPTION, same as -s.

  -a, --all        print all information
  -m, --machine    print the machine (hardware) type
  -n, --nodename   print the machine's network node hostname
  -r, --release    print the operating system release
  -s, --sysname    print the operating system name
  -p, --processor  print the host processor type
  -v               print the operating system version
      --help       display this help and exit
      --version    output version information and exit

  Report bugs to sh-utils-bugs AT gnu DOT ai DOT mit DOT edu

And the same on Solaris :

# uname -rs
SunOS 5.6
# uname -
usage:  uname [-snrvmapiX]
	uname [-S system_name]

They all seem to have a '-p' that djgpp is missing.

> -: 
> -: As for a new member of `struct utsname', I'm not particularly against
> -: it, although we should at least go out and see if some other platform
> -: adds that, and if so, make the additional member have the same name.
> -: Also, if detecting x87 could be dangerous (i.e. risk crashing the
> -: program), I would vote against it.
> 
> We have the lib function _detect_80387() in djgpp; is there a danger of
> this crashing inside a script?  Even if it can, is this a bad thing if it
> is just an optional switch?

Opinions may vary, but there is a lot of automated configuration tools
That rely on uname (autoconf(config.guess))  and to have a package crash
in the configuration stage, can be really annoying 8-).


-- 
au revoir, alain
----
Aussi haut que l'on soit assis, on est toujours assis que sur son cul !!!

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019