table of contents
- experimental 0.194+20260315-1
| GELF_UPDATE_LIB(3) | Libelf Programmer's Manual | GELF_UPDATE_LIB(3) |
NAME¶
gelf_update_lib - Update prelink library in table at the given index
SYNOPSIS¶
#include <gelf.h> int gelf_update_lib (Elf_Data *data, int ndx, GElf_Lib *src);
DESCRIPTION¶
Copy a class-independent prelink library table entry from src into the SHT_GNU_LIBLIST. section associated with data at index ndx.
data must be an Elf_Data* associated with a section of type SHT_GNU_LIBLIST. data->d_type should be ELF_T_LIB. SHT_GNU_LIBLIST sections are used by the prelink utility. See https://sourceware.org/gnu-gabi/prelink.txt for more information.
PARAMETERS¶
RETURN VALUE¶
On success, this function returns a non-zero value and updates the prelink library table entry at index ndx in data. The section associated with data is flagged with ELF_F_DIRTY. On failure, zero is returned and elf_errno is set. If data is NULL, then zero is returned and elf_errno is not set.
SEE ALSO¶
gelf_getlib(3), libelf(3), elf(5)
ATTRIBUTES¶
| Interface | Attribute | Value |
| gelf_update_lib () | Thread safety | MT-Safe |
REPORTING BUGS¶
Report bugs to <elfutils-devel@sourceware.org> or https://sourceware.org/bugzilla/.
HISTORY¶
gelf_update_lib first appeared in elfutils 0.95. This function is an elfutils libelf extension and may not be available in other libelf implementations.
| 2025-12-31 | Libelf |