2 .\" Copyright 1989 AT&T Copyright (c) 2001, Sun Microsystems, Inc. All Rights Reserved
3 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
4 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
5 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
6 .TH ELF32_FSIZE 3ELF "Jul 11, 2001"
8 elf32_fsize, elf64_fsize \- return the size of an object file type
12 cc [ \fIflag\fR ... ] \fIfile\fR ... \fB-lelf\fR [ \fIlibrary\fR ... ]
15 \fBsize_t\fR \fBelf32_fsize\fR(\fBElf_Type\fR \fItype\fR, \fBsize_t\fR \fIcount\fR, \fBunsigned\fR \fIver\fR);
20 \fBsize_t\fR \fBelf64_fsize\fR(\fBElf_Type\fR \fItype\fR, \fBsize_t\fR \fIcount\fR, \fBunsigned\fR \fIver\fR);
26 \fBelf32_fsize()\fR gives the size in bytes of the 32-bit file representation
27 of \fIcount\fR data objects with the given \fBtype\fR. The library uses version
28 \fBver\fR to calculate the size. See \fBelf\fR(3ELF) and
29 \fBelf_version\fR(3ELF).
32 Constant values are available for the sizes of fundamental types:
36 \fBElf_Type File Size Memory Size
37 ELF_T_ADDR ELF32_FSZ_ADDR sizeof(Elf32_Addr)
38 ELF_T_BYTE 1 sizeof(unsigned char)
39 ELF_T_HALF ELF32_FSZ_HALF sizeof(Elf32_Half)
40 ELT_T_OFF ELF32_FSZ_OFF sizeof(Elf32_Off)
41 ELF_T_SWORD ELF32_FSZ_SWORD sizeof(Elf32_Sword)
42 ELF_T_WORD ELF32_FSZ_WORD sizeof(Elf32_Word)\fR
48 \fBelf32_fsize()\fR returns \fB0\fR if the value of \fBtype\fR or \fBver\fR is
49 unknown. See \fBelf32_xlatetof\fR(3ELF) for a list of the \fBtype\fR values.
52 For the 64\(mibit class, replace 32 with 64 as appropriate.
56 See \fBattributes\fR(5) for descriptions of the following attributes:
64 ATTRIBUTE TYPE ATTRIBUTE VALUE
66 Interface Stability Stable
74 \fBelf\fR(3ELF), \fBelf32_xlatetof\fR(3ELF), \fBelf_version\fR(3ELF),
75 \fBlibelf\fR(3LIB), \fBattributes\fR(5)