elf_kind - Man Page
Determine the type of file represented by an ELF descriptor.
Synopsis
#include <libelf.h> Elf_Kind elf_kind(Elf *elf);
Description
The elf_kind function determines the file type of the file represented by elf. This type identifies whether the descriptor represents an ELF object, an archive member, or some other type of file.
Parameters
- elf
The ELF descriptor.
Return Value
The file type of the file represented by elf. The possible return value are
- ELF_K_NONE
Unknown file type.
- ELF_K_AR
Archive member.
- ELF_K_COFF
COFF object file. COFF is not supported by elfutils libelf.
- ELF_K_ELF
ELF object file.
See Also
Attributes
For an explanation of the terms used in this section, see attributes(7).
| Interface | Attribute | Value |
|---|---|---|
| elf_kind() | Thread safety | MT-Safe |
Reporting Bugs
Report bugs to <elfutils-devel@sourceware.org> or https://sourceware.org/bugzilla/.
Referenced By
2025-03-31 Libelf Programmer's Manual