intro(3) C2 Trusted DG/UX 5.4.2T intro(3)
NAME
intro - introduction to subroutines and libraries
DESCRIPTION
This section describes functions found in various libraries supplied
with the DG/UX System. Declarations for some of these functions may
be obtained from #include files indicated on the appropriate pages.
The man pages are grouped by using various suffixes after the number
3. They are sorted together in the manual.
(3C) These functions make up the "general" C functions, many of which
are part of the ANSI C language definition. The others have
traditionally been part of libc on AT&T Unix-based systems.
(3E) These functions constitute the ELF library, libelf.
(3G) These are general C functions found in libgen.
(3M) These functions constitute the math library, libm. They are not
automatically loaded by the C compiler, cc(1); however, the link
editor searches this library under the -lm option. Declarations
for these functions may be obtained from the #include file
<math.h>. Several generally useful mathematical constants are
also defined there (see math(5)).
(3N) These functions constitute the Internet network library, and
Network Services library.
(3R) RPC (Remote Procedure Call) related functions.
(3S) These functions constitute the standard I/O package (see
stdio(3S)). Declarations for them may be obtained from the
#include file <stdio.h>. The functions themselves live in libc.
(3T) These functions constitute the Trusted DG/UX library, libtrust.
(3W) Multinational Language Set (MNLS) functions - libw.
(3X) Various specialized libraries. The library names in which these
functions are found are given on the appropriate pages.
The DG/UX System provides a number of Software Development
Environments, or SDEs. An SDE represents a target binary or object
interface. It is made up of a set of libraries (object and binary
interfaces) and header files (constants, data structures, types) that
may be used together to create applications that adhere to a
particular binary or object interface standard.
See sde(5) and sde-target(1) for how to select SDEs. The function
groupings described above may not be available in all the SDEs. Some
functions even appear in different libraries from one SDE to another.
The DG/UX system supports two object formats, commonly known as COFF
and ELF. The COFF format is associated with pre-V.4 Unix systems
from AT&T. The ELF format originates with V.4 Unix systems. In
general, the SDEs deal with one specific object file format.
However, the tools in the ELF SDE are capable of reading COFF
objects.
The following SDEs are available:
m88kdguxelf This is the System V Release 4 ELF environment. This
environment contains ELF shared libraries, as well as
Licensed material--property of copyright holder(s) 1
intro(3) C2 Trusted DG/UX 5.4.2T intro(3)
several ELF static libraries. In order to avoid
duplication, some libraries in this environment are
COFF libraries that are shared with the COFF
environments.
m88kdguxcoff This is the System V Release 3 COFF development
environment. This environment corresponds to m88kdgux
on DG/UX 4.3x systems. It is provided for development
of COFF-based applications to run on DG/UX Release 5.4
or later.
m88kocs This COFF environment provides the 88open OCS standard
interface. It should be used for developing
applications which include object files and libraries
that are intended to be OCS-compliant.
m88kbcs The m88kbcs environment is essentially unchanged from
DG/UX 4.3x. It is intended for developing applications
consisting entirely of statically linked COFF
executables that adhere to the 88open BCS. It provides
a libc compatible with the System V Interface
Definition, Edition 2, and containing BSD, POSIX, and
ANSI extensions.
m88kdgux This environment is a synonym for one of the other
environments. It provides the default if no other
environment is explicitly requested. In DG/UX 4.3x,
this was a synonym for what is now m88kdguxcoff. In
DG/UX Release 5.4 this is a synonym for m88kdguxelf.
All of the above environments are intended to provide the set of
interfaces specified by the OCS standard. In the ELF environments,
these interfaces may not appear in the same libraries specified by
the OCS. This is due to restructuring by AT&T in System V Release 4.
See below for more information.
A few functions are located in different libraries in the ELF
environments than in the COFF environments. The regex and regcmp
functions are available in libPW in the COFF environments, and in
libgen in the ELF environments. The nlist function is available in
libc in the COFF environments, and in libelf in the ELF environments.
Under the COFF environments, the default floating point environment
enables the divide by zero, floating point overflow, and invalid
operation exceptions. These exceptions would be disabled if
<ieeefp.h> is included. Under the ELF environment, the default
floating point environment does not enable any of the exceptions.
In addition, many functions found in libc in the COFF environments
are found in libdgc in the DG/UX Release 5.4 ELF environment. The
reason for this split is to facilitate ABI compliance in the future.
The general classes that have been moved are the RPC/YP (3N)
functions, socket/internet functions (3N), domain name service
functions (3N), Berkeley 4.2 and 4.3 extensions, and miscellaneous DG
Licensed material--property of copyright holder(s) 2
intro(3) C2 Trusted DG/UX 5.4.2T intro(3)
extensions.
This is the list of symbols in libdgc in the ELF environment. These
symbols are located in libc in the COFF environments.
accept addexportent
addmntent alphasort
authdescreate authdesgetucred
authnonecreate authunixcreate
authunixcreatedefault bcmp
bcopy berksignal
berksigpause bind
bindresvport bzero
callrpc cbccrypt
clntbroadcast clntcreate
clntpcreateerror clntperrno
clntperror clntspcreateerror
clntsperrno clntsperror
clntrawcreate clnttcpcreate
clntudpcreate connect
dbmclearerr dbmclose
dbmdelete dbmerror
dbmfetch dbmfirstkey
dbmnextkey dbmopen
dbmstore dessetparity
dgallowshareddescriptorattach dgattachtoshareddescriptors
dgblockseek dgdecryptsessionkey
dgencryptsessionkey dgexterrno
dgfileinfo dgflock
dgfstat dggetrootkey
dgipcinfo dglcntl
dglockkill dglockreset
dglockwait dgmknod
dgmount dgmstat
dgpaginginfo dgprocessinfo
dgseek dgsetcpdlimits
dgsetsecretkey dgstat
dgsysinfo dgsysctl
dgunbufferedread dgunbufferedwrite
dgxtrace dncomp
dnexpand ecbcrypt
endexportent endfsent
endhostent endmntent
endnetent endnetgrent
endprotoent endrpcent
endservent etheraton
etherhostton etherline
etherntoa etherntohost
extendedperror ftime
getmyaddress getdomainname
getdtablesize getexportent
getexportopt getfh
getfsent getfsfile
getfsspec getfstype
Licensed material--property of copyright holder(s) 3
intro(3) C2 Trusted DG/UX 5.4.2T intro(3)
gethostbyaddr gethostbyname
gethostent gethostid
gethostname getmntent
getnetbyaddr getnetbyname
getnetent getnetgrent
getnetname getpagesize
getpeername getpgrp2
getpriority getprotobyname
getprotobynumber getprotoent
getpsr getrpcbyname
getrpcbynumber getrpcent
getrpcport getrusage
getservbyname getservbyport
getservent getsockname
getsockopt getwd
herrlist herrno
hasmntopt herror
host2netname index
inetaddr inetlnaof
inetmakeaddr inetnetof
inetnetwork inetntoa
initstate innetgr
isalphanum ishex
itoa keydecryptsession
keyencryptsession keygendes
keysetsecret killpg
listen memctl
mkstemp msgsys
netname2host netname2user
ptype pmapgetmaps
pmapgetport pmaprmtcall
pmapset pmapunset
random rcmd
recomp reexec
reboot recv
recvfrom recvmsg
registerrpc remexportent
resinit resmkquery
ressend rexec
rindex rpccreateerr
rresvport rtime
ruserok scandir
select semsys
send sendmsg
sendto setdomainname
setegid seteuid
setexportent setfsent
sethostent sethostid
sethostname setmntent
setnetent setnetgrent
setpgrp2 setpriority
setprotoent setpsr
setregid setreuid
Licensed material--property of copyright holder(s) 4
intro(3) C2 Trusted DG/UX 5.4.2T intro(3)
setrpcent setservent
setsockopt setstate
shmsys shutdown
sigblock sigret
sigsetmask sigstack
socket socketpair
srandom strnsave
strsave svcfdset
svcgetreq svcgetreqset
svcregister svcrun
svcsendreply svcunregister
svcerrauth svcerrdecode
svcerrnoproc svcerrnoprog
svcerrprogvers svcerrsystemerr
svcerrweakauth svcfdcreate
svcrawcreate svctcpcreate
svcudpcreate swapon
user2netname utimes
vhangup vlimit
vtimes wait3
wait4 xdracceptedreply
xdrarray xdrauthunixparms
xdrbool xdrbytes
xdrcallhdr xdrcallmsg
xdrchar xdrdouble
xdrenum xdrfloat
xdrfree xdrint
xdrlong xdropaque
xdropaqueauth xdrpmap
xdrpmaplist xdrpointer
xdrreference xdrrejectedreply
xdrreplymsg xdrshort
xdrstring xdruchar
xdruint xdrulong
xdrushort xdrunion
xdrvector xdrvoid
xdrwrapstring xdrmemcreate
xdrreccreate xdrrecendofrecord
xdrreceof xdrrecskiprecord
xdrstdiocreate xprtregister
xprtunregister ypall
ypbind ypfirst
ypgetdefaultdomain ypgethostbyname
ypmaster ypmatch
ypnext yporder
ypunbind ypupdate
yperrstring ypproterr
Many of the internationalization features, such as message catalog
facilities (see gettxt(3C)) that are available in the m88kdguxelf
environment are absent from the m88kdguxcoff, m88kbcs, and m88kocs
environments. Many other internationalization features, such as
strcoll(3C), are present, but offer only C locale behavior.
Licensed material--property of copyright holder(s) 5
intro(3) C2 Trusted DG/UX 5.4.2T intro(3)
B1 Trusted DG/UX Library
This is the list of symbols in libtrust in the ELF environment.
acladdperm aclalloc
aclcalcmask aclcopyentry
aclcreateentry acldeleteentry
acldeleteperm aclfree
aclgetentry aclgetperm
aclgettag acltoexport
aclpackagesize aclread
aclrewind aclsetperm
aclsettag aclfromexport
aclvalid aclwrite
aclallocated aclinternalcopy
aclinternalcopyfrombuffer aclclear
aclentryvalid aclorder
aclnocalcmask aclinternalclear
aclinternalfree aclprintf
aclfprintf aclgettext
aclreadject aclwriteject
aaaccounteverdenied aaaccounteveruser
aaaccountlastdeniedmac aaaccountlastdeniedwhat
aaaccountlastdeniedwhen aaaccountlastdeniedwhere
aaaccountlastusedmac aaaccountlastusedwhat
aaaccountlastusedwhen aaaccountlastusedwhere
aagetfilemaclabel aagetsessionkit
aaineffect aamaccheckandlabel
aamacineffect aanotepwchangefailed
aaotherpwwarning aapasswordchange
aapasswordcheck aapasswordcritique
aapasswordexpired aapasswordoverride
aapasswordwarning aaproxyidandsecurity
aaservicehomedirectory aaservicepriority
aaserviceprogram aaservicerootdirectory
aasetidandsecurity aasupgrpt
aatrunctodhms aatrustedprocess
aausergecos aausergid
aauseruid addaclsct
addauditmasksect adddevsect
addgenericsect addheadersect
addidssect addintssect
addmodesect addopaquesect
addstringssect addusernamesect
audreccreate audrecdiscard
audrecsetdivision audrecwrite
macdominate macequal
macfgetflabel macfreelabel
macgetflabel macgetplabel
macgetsize macglb
maclabeltotext maclub
macsetflabel macsetplabel
mactextlabellnth mactexttolabel
macvalid macaliastolabel
macaliastocategory macaliastohierarchy
Licensed material--property of copyright holder(s) 6
intro(3) C2 Trusted DG/UX 5.4.2T intro(3)
maccategorytoalias macfsetflabel
machierarchytoalias maclabeltoalias
macreadject macwriteject
rangereadject rangewriteject
rangetoalias rangegetsize
macinfoclose macinfoopen
macinternalalloc macinternalfree
rangeinternalalloc rangeinternalfree
macinternalcopy macinternaldominate
macinternalequal macinternalglb
macinternallub macinternalvalid
All other symbols in libtrust should be ignored, and will be removed
in future releases of Trusted DG/UX.
Definitions
character Any bit pattern able to fit into a byte on the
machine.
null character A character with value 0, represented in the C
language as '\0'.
character array A sequence of characters.
null-terminated character array
A sequence of characters, the last of which is the
null character.
string is a designation for a null-terminated character
array.
null string A character array containing only the null character.
NULL pointer The value that is obtained by casting 0 into a
pointer. The C language guarantees that this value
will not match that of any legitimate pointer, so
many functions that return pointers return it to
indicate an error.
NULL Defined as 0 in <stdio.h>; the user may include an
appropriate definition if not using <stdio.h>.
FILES
/usr/lib/libc.a Standard C library
/usr/lib/libcrypt.a Alternate encryption library
/usr/lib/libdbm.a Database access library
/lib/libcurses.a Terminal screen handling library
/usr/lib/libm.a Math library
/usr/lib/libmalloc.a Alternate memory management library
/usr/lib/libmp.a Multi-precision integer math library
/usr/lib/libnsls.a Network Services library
/lib/libtermcap.a termcap access library
/usr/lib/libPW.a Programmer Workbench library
/usr/sde/*/lib/* Any SDE-specific components linked via elinks
/usr/lib/libdl.a Dynamic linking interfaces (ELF)
Licensed material--property of copyright holder(s) 7
intro(3) C2 Trusted DG/UX 5.4.2T intro(3)
/usr/lib/libdgc.a Non-AT&T based portion of libc (ELF)
/usr/lib/libelf.a Object format interfaces (COFF)
/usr/lib/libgen.a General library functions (COFF)
/usr/lib/libmail.a Mail file interfaces (ELF)
/usr/lib/libtrust.a Trusted DG/UX interfaces (ELF)
DIAGNOSTICS
Functions in the C and math Libraries (3C and 3M) may return the
conventional values 0 or ±HUGE when the function is undefined for the
given arguments or when the value is not representable. These are
the largest-magnitude single-precision floating-point numbers; HUGE
is defined in the <math.h> header file. In these cases, the external
variable errno (see intro(2)) is set to the value EDOM or ERANGE.
SEE ALSO
ar(1), cc(1), ld(1), lint(1), nm(1), sde-target(1), intro(2),
intro(3M), intro(3N), stdio(3S), math(5).
CAUTION
Many of the functions in the libraries call and/or refer to other
functions and external variables described in this section and in
Chapter 2 (System Calls). If a program inadvertently defines a
function or external variable with the same name, the presumed
library version of the function or external variable may not be
loaded. The lint(1) program checker reports name conflicts of this
kind as multiple declarations of the names in question. Definitions
for sections 2, 3C, 3N, 3R and 3S are checked automatically. Other
definitions can be included by using the-l option (for example, -lm
includes definitions for the math library, section 3M). Use of lint
is highly recommended.
Licensed material--property of copyright holder(s) 8