AT&T UNIX™PC Unix System V Users Manual - tenox
AT&T UNIX™PC Unix System V Users Manual - tenox AT&T UNIX™PC Unix System V Users Manual - tenox
� LDFCN( 4) LDFCN( 4) NAME ldfcn - common object file access routines SYNOPSIS #include #include #include DESCRIPTION The common object file access routines are a collection of functions for reading an object file that is in VAX or 3B20S (common) object file form. Although the calling program must know the detailed structure of the parts of the object file that it processes, the routines effectively insulate the calling program from knowledge of the overall structure of the object file. The interface between the calling program and the object file access routines is based on the defined type LDFILE, defined as struct ldfile, declared in the header file ldfcn.h. The primary purpose of this structure is to provide uniform access to both simple object files and to object files that are members of an archive file. The function ldopen(3X) allocates and initializes the LDFILE structure and returns a pointer to the structure to the calling program. The fields of the LDFILE structure may be accessed individually through macros defined in ldfcn.h and contain the following information: LDFIT..E *ldptr; TYPE(ldptr) IOPTR(Idptr) OFFSET(Idptr) The file magic number, used to distinguish between archive members and simple object files. The file pointer returned by fopen and used by the standard input/output functions. The file address of the beginning of the object file; the offset is non-zero if the object file is a member of an archive file. HEADER(Idptr) The file header structure of the object file. The object file access functions themselves may be divided into four categories: (1) functions that open or close an object file ldopen(3X) and ldaopen open a common object file ldclose(3X) and ldaclose close a common object file (2) functions that read header or symbol table information ldahread(3X) read the archive header of a member of an archive file - 1 -
- Page 1038 and 1039: A.OUT (4) A.OUT (4) char n_numaux;
- Page 1041 and 1042: ADF ( 4) (AT&T UNIX PC only ) ADF (
- Page 1043 and 1044: ADF ( 4 ) (AT&T UNIX PC only ) \ \
- Page 1045 and 1046: ADF ( 4) (AT&T UNIX PC only ) FORMA
- Page 1047 and 1048: ADF (4) (AT&T UNIX PC only ) ADF (4
- Page 1049 and 1050: ADF (4) (AT&T UNIX PC only ) ADF (
- Page 1051 and 1052: ADF ( 4) (AT&T UNIX PC only ) ADF (
- Page 1053 and 1054: ADF ( 4 ) (AT&T UNIX PC only ) Toke
- Page 1055 and 1056: AR( 4 ) AR ( 4) NAME ar - common ar
- Page 1057: CHECKLIST ( 4 ) CHECKLIST ( 4 ) NAM
- Page 1060 and 1061: I I I I I I II I I I I I I I I I I
- Page 1063 and 1064: Dffi ( 4 ) Dffi ( 4 ) NAME dir - fo
- Page 1065: FILEHDR (4) (not. on PDP-11) FILEHD
- Page 1068 and 1069: FONT ( 4) (AT&T UNIX PC only ) FONT
- Page 1070 and 1071: I�
- Page 1072 and 1073: FS (4) FS (4) S_type indicates the
- Page 1074 and 1075: (�
- Page 1076 and 1077: FSPEC ( 4) FSPEC ( 4) Several UNIX
- Page 1078 and 1079: GETTYDEFS ( 4) GETTYDEFS ( 4 ) sett
- Page 1080 and 1081: � , __
- Page 1082 and 1083: INITTAB ( 4) INITTAB ( 4) I etclini
- Page 1084 and 1085: I I �I I I I I � I I 1� 1 1 I
- Page 1086 and 1087: (� .
- Page 1090 and 1091: LDFCN( 4) LDFCN ( 4) ldfhread(3X) r
- Page 1093: LINENUM ( 4) LINENUM ( 4) NAME line
- Page 1096 and 1097: MASTER ( 4) Field 1: Field 2: MASTE
- Page 1099 and 1100: PASSWD ( 4 ) PASSWD ( 4 ) NAME pass
- Page 1101 and 1102: PHONE ( 4) (AT&T UNIX PC Only ) PHO
- Page 1103 and 1104: PHONE ( 4) (AT&T UNIX PC Only ) PHO
- Page 1105: PNCH ( 4) PNCH(4) NAME pnch - file
- Page 1109 and 1110: RELOC ( 4) RELOC ( 4) NAME reloc -
- Page 1111 and 1112: RELOC ( 4) RELOC ( 4) R_PCRLONG A "
- Page 1113 and 1114: � I SCCSFILE ( 4) SCCSFILE ( 4 )
- Page 1115 and 1116: SCCSFILE ( 4) SCCSFILE ( 4) get com
- Page 1117: � SCNHDR ( 4) SCNHDR ( 4) NAME sc
- Page 1120 and 1121: I� "--- - . . .� . ' . ) I ry'-
- Page 1122 and 1123: SYMS (4) union auxent { struct { lo
- Page 1124 and 1125: UA ( 4) (AT&T UNIX PC only ) UA (4)
- Page 1126 and 1127: UA (4) (AT&T UNIX PC only ) UA (4)
- Page 1128 and 1129: UA ( 4) (AT&T UNIX PC only ) UA ( 4
- Page 1130 and 1131: UA ( 4) (AT&T UNIX PC only ) UA ( 4
- Page 1132 and 1133: UTMP ( 4) UTMP ( 4) FILES I* Specia
- Page 1135 and 1136: f""" " : � � ASCII ( 5 ) ASCII
- Page 1137: ENVIRON (5) ENVIRON (5) NAME enviro
�<br />
LDFCN( 4) LDFCN( 4)<br />
NAME ldfcn - common object file access routines<br />
SYNOPSIS<br />
#include <br />
#include <br />
#include <br />
DESCRIPTION<br />
The common object file access routines are a collection of functions<br />
for reading an object file that is in VAX or 3B20S (common)<br />
object file form. Although the calling program must know the<br />
detailed structure of the parts of the object file that it processes,<br />
the routines effectively insulate the calling program from<br />
knowledge of the overall structure of the object file.<br />
The interface between the calling program and the object file<br />
access routines is based on the defined type LDFILE, defined as<br />
struct ldfile, declared in the header file ldfcn.h. The primary<br />
purpose of this structure is to provide uniform access to both simple<br />
object files and to object files that are members of an archive<br />
file.<br />
The function ldopen(3X) allocates and initializes the LDFILE<br />
structure and returns a pointer to the structure to the calling program.<br />
The fields of the LDFILE structure may be accessed individually<br />
through macros defined in ldfcn.h and contain the following<br />
information:<br />
LDFIT..E *ldptr;<br />
TYPE(ldptr)<br />
IOPTR(Idptr)<br />
OFFSET(Idptr)<br />
The file magic number, used to distinguish<br />
between archive members and simple object files.<br />
The file pointer returned by fopen and used by<br />
the standard input/output functions.<br />
The file address of the beginning of the object<br />
file; the offset is non-zero if the object file is a<br />
member of an archive file.<br />
HEADER(Idptr) The file header structure of the object file.<br />
The object file access functions themselves may be divided into<br />
four categories:<br />
(1) functions that open or close an object file<br />
ldopen(3X) and ldaopen<br />
open a common object file<br />
ldclose(3X) and ldaclose<br />
close a common object file<br />
(2) functions that read header or symbol table information<br />
ldahread(3X)<br />
read the archive header of a member of<br />
an archive file<br />
- 1 -