Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

uname(1)

UNAME(2)  —  Silicon Graphics

NAME

uname − get name of current UNIX system

SYNOPSIS

#include <sys/utsname.h>

int uname (name)
struct utsname ∗name;

DESCRIPTION

Uname stores information identifying the current UNIX system in the structure pointed to by name.

Uname uses the structure defined in <sys/utsname.h>:

structutsname {
charsysname[9];
charnodename[9];
charrelease[9];
charversion[9];
charmachine[9];
};
extern struct utsname utsname;

The fields of the utsname structure contain information as follows:

sysname, nodename:set to first 8 chars
of sethostname()
release:IRIS software release
version:software version (timestamp)
machine one of:m68000
m68020

Uname will fail if name points to an invalid address.  ­[EFAULT]

RETURN VALUE

Upon successful completion, a non-negative value is returned.  Otherwise, −1 is returned and errno is set to indicate the error. 

SEE ALSO

uname(1). 

ASSEMBLER

moveq#57,D0
movlname,A0| fetch argument
sublA1,A1| uname
trap#0

Carry bit set on failure and cleared on success. 

Version 3.6  —  December 20, 1987

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026