control a file descriptor
cc [flag . . . ] file . . . -lelf [library] . . .
int elf_cntl(Elf elf, Elf_Cmd cmd);
instructs the library to modify its behavior with respect to an
descriptor can have multiple activations,
descriptors may share a single file descriptor.
commands apply to all activations of
Moreover, if the
descriptor is associated
with an archive file, descriptors for members within
the archive will also be affected as described below.
Unless stated otherwise, operations on archive members
do not affect the descriptor for the containing archive.
argument tells what actions to take and may have the following values.
This value tells the library not to use the file descriptor
A program should use this command when it has requested all the
information it cares to use and wishes to avoid the overhead
of reading the rest of the file.
The memory for all completed operations remains valid, but later
file operations, such as the initial
for a section, will fail if the data is not in memory already.
This command is similar to
except it forces the library to read the rest of the file.
A program should use this command when it must close the file
descriptor but has not yet read everything it needs from the file.
command, future operations, such as
will use the memory version of the file without needing
to use the file descriptor.
succeeds, it returns zero.
was null or an error occurred, and the function returns -1.
If the program wishes to use the ``raw'' operations [see
disabling the file descriptor with
ELF_C_FDDONE or ELF_C_FDREAD,
it must execute the raw operations explicitly beforehand.
Otherwise, the raw file operations will fail.
makes the entire image available, thus supporting subsequent
© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 25 April 2004