Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ elf32_getshdr(3E) — SunOS 5.6

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

elf(3E)

elf_flagdata(3E)

elf_getscn(3E)

elf_strptr(3E)

attributes(5)

elf32_getshdr(3E)

NAME

elf32_getshdr − retrieve class-dependent section header

SYNOPSIS

cc [ flag ... ] file ... −lelf [ library ... ]

#include <libelf.h>

Elf32_Shdr ∗elf32_getshdr(Elf_Scn ∗scn);

DESCRIPTION

For a 32-bit class file, elf32_getshdr() returns a pointer to a section header for the section descriptor scn. Otherwise, the file is not a 32-bit class file, scn was NULL , or an error occurred; elf32_getshdr() then returns NULL .

The header includes the following members. 

Elf32_Wordsh_name;
Elf32_Wordsh_type;
Elf32_Wordsh_flags;
Elf32_Addrsh_addr;
Elf32_Offsh_offset;
Elf32_Wordsh_size;
Elf32_Wordsh_link;
Elf32_Wordsh_info;
Elf32_Wordsh_addralign;
Elf32_Wordsh_entsize;

If the program is building a new file, it is responsible for creating the file’s ELF header before creating sections. 

ATTRIBUTES

See attributes(5) for descriptions of the following attributes:

ATTRIBUTE TYPE ATTRIBUTE VALUE
MT-Level MT-Safe

SEE ALSO

elf(3E), elf_flagdata(3E), elf_getscn(3E), elf_strptr(3E), attributes(5)

SunOS 5.6  —  Last change: 29 Dec 1996

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026