summaryrefslogtreecommitdiff
path: root/usr/src/man/man3elf/gelf.3elf
blob: cbddcc37e1520d78b0cd77f078e037637a82944d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
'\" te
.\" Copyright (c) 2004, Sun Microsystems, Inc., All Rights Reserved
.\" 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.
.\" 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.
.\" 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]
.TH GELF 3ELF "Jun 8, 2004"
.SH NAME
gelf, gelf_checksum, gelf_fsize, gelf_getcap, gelf_getclass, gelf_getdyn,
gelf_getehdr, gelf_getmove, gelf_getphdr, gelf_getrel, gelf_getrela,
gelf_getshdr, gelf_getsym, gelf_getsyminfo, gelf_getsymshndx, gelf_newehdr,
gelf_newphdr, gelf_update_cap, gelf_update_dyn, gelf_update_ehdr,
gelf_update_getmove, gelf_update_move, gelf_update_phdr, gelf_update_rel,
gelf_update_rela, gelf_update_shdr, gelf_update_sym, gelf_update_symshndx,
gelf_update_syminfo, gelf_xlatetof, gelf_xlatetom \- generic class-independent
ELF interface
.SH SYNOPSIS
.LP
.nf
\fBcc\fR [ \fIflag\fR... ] \fIfile\fR...  \fB\(milelf\fR [ \fIlibrary\fR... ]
#include <gelf.h>

\fBlong\fR \fBgelf_checksum\fR(\fBElf *\fR\fIelf\fR);
.fi

.LP
.nf
\fBsize_t\fR \fBgelf_fsize\fR(\fBElf *\fR\fIelf\fR, \fBElf_Type\fR \fItype\fR, \fBsize_t\fR \fIcnt\fR, \fBunsigned\fR \fIver\fR);
.fi

.LP
.nf
\fBint\fR \fBgelf_getcap\fR(\fBElf_Data *\fR\fIsrc\fR, \fBint\fR \fIndx\fR, \fBGElf_Cap *\fR\fIdst\fR);
.fi

.LP
.nf
\fBint\fR \fBgelf_getclass\fR(\fBElf *\fR\fIelf\fR);
.fi

.LP
.nf
\fBGElf_Dyn *\fR\fBgelf_getdyn\fR(\fBElf_Data *\fR\fIsrc\fR, \fBint\fR \fIndx\fR, \fBGElf_Dyn *\fR\fIdst\fR);
.fi

.LP
.nf
\fBGElf_Ehdr *\fR\fBgelf_getehdr\fR(\fBElf *\fR\fIelf\fR, \fBGElf_Ehdr *\fR\fIdst\fR);
.fi

.LP
.nf
\fBGElf_Move *\fR\fBgelf_getmove\fR(\fBElf_Data *\fR\fIsrc\fR, \fBint\fR \fIndx\fR, \fBGElf_Move *\fR\fIdst\fR);
.fi

.LP
.nf
\fBGElf_Phdr *\fR\fBgelf_getphdr\fR(\fBElf *\fR\fIelf\fR, \fBint\fR \fIndx\fR, \fBGElf_Phdr *\fR\fIdst\fR);
.fi

.LP
.nf
\fBGElf_Rel *\fR\fBgelf_getrel\fR(\fBElf_Data *\fR\fIsrc\fR, \fBint\fR \fIndx\fR, \fBGElf_Rel *\fR\fIdst\fR);
.fi

.LP
.nf
\fBGElf_Rela *\fR\fBgelf_getrela\fR(\fBElf_Data *\fR\fIsrc\fR, \fBint\fR \fIndx\fR, \fBGElf_Rela *\fR\fIdst\fR);
.fi

.LP
.nf
\fBGElf_Shdr *\fR\fBgelf_getshdr\fR(\fBElf_Scn *\fR\fIscn\fR, \fBGElf_Shdr *\fR\fIdst\fR);
.fi

.LP
.nf
\fBGElf_Sym *\fR\fBgelf_getsym\fR(\fBElf_Data *\fR\fIsrc\fR, \fBint\fR \fIndx\fR, \fBGElf_Sym *\fR\fIdst\fR);
.fi

.LP
.nf
\fBGElf_Syminfo *\fR\fBgelf_getsyminfo\fR(\fBElf_Data *\fR\fIsrc\fR, \fBint\fR \fIndx\fR, \fBGElf_Syminfo *\fR\fIdst\fR);
.fi

.LP
.nf
\fBGElf_Sym *\fR\fBgelf_getsymshndx\fR(\fBElf_Data *\fR\fIsymsrc\fR, \fBElf_Data *\fR\fIshndxsrc\fR,
     \fBint\fR \fIndx\fR, \fBGElf_Sym *\fR\fIsymdst\fR, \fBElf32_Word *\fR\fIshndxdst\fR);
.fi

.LP
.nf
\fBunsigned long\fR \fBgelf_newehdr\fR(\fBElf *\fR\fIelf\fR, \fBint\fR \fIclass\fR);
.fi

.LP
.nf
\fBunsigned long\fR \fBgelf_newphdr\fR(\fBElf *\fR\fIelf\fR, \fBsize_t\fR \fIphnum\fR);
.fi

.LP
.nf
\fBint\fR \fBgelf_update_cap\fR(\fBElf_Data *\fR\fIdst\fR, \fBint\fR \fIndx\fR, \fBGElf_Cap *\fR\fIsrc\fR);
.fi

.LP
.nf
\fBint\fR \fBgelf_update_dyn\fR(\fBElf_Data *\fR\fIdst\fR, \fBint\fR \fIndx\fR, \fBGElf_Dyn *\fR\fIsrc\fR);
.fi

.LP
.nf
\fBint\fR \fBgelf_update_ehdr\fR(\fBElf *\fR\fIelf\fR, \fBGElf_Ehdr *\fR\fIsrc\fR);
.fi

.LP
.nf
\fBint\fR \fBgelf_update_move\fR(\fBElf_Data *\fR\fIdst\fR, \fBint\fR \fIndx\fR, \fBGElf_Move *\fR\fIsrc\fR);
.fi

.LP
.nf
\fBint\fR \fBgelf_update_phdr\fR(\fBElf *\fR\fIelf\fR, \fBint\fR \fIndx\fR, \fBGElf_Phdr *\fR\fIsrc\fR);
.fi

.LP
.nf
\fBint\fR \fBgelf_update_rel\fR(\fBElf_Data *\fR\fIdst\fR, \fBint\fR \fIndx\fR, \fBGElf_Rel *\fR\fIsrc\fR);
.fi

.LP
.nf
\fBint\fR \fBgelf_update_rela\fR(\fBElf_Data *\fR\fIdst\fR, \fBint\fR \fIndx\fR, \fBGElf_Rela *\fR\fIsrc\fR);
.fi

.LP
.nf
\fBint\fR \fBgelf_update_shdr\fR(\fBElf_Scn *\fR\fIdst\fR, \fBGElf_Shdr *\fR\fIsrc\fR);
.fi

.LP
.nf
\fBint\fR \fBgelf_update_sym\fR(\fBElf_Data *\fR\fIdst\fR, \fBint\fR \fIndx\fR, \fBGElf_Sym *\fR\fIsrc\fR);
.fi

.LP
.nf
\fBint\fR \fBgelf_update_syminfo\fR(\fBElf_Data *\fR\fIdst\fR, \fBint\fR \fIndx\fR, \fBGElf_Syminfo *\fR\fIsrc\fR);
.fi

.LP
.nf
\fBint\fR \fBgelf_update_symshndx\fR(\fBElf_Data *\fR\fIsymdst\fR, \fBElf_Data *\fR\fIshndxdst\fR, \fBint\fR \fIndx\fR,
     \fBGElf_Sym *\fR\fIsymsrc\fR, \fBElf32_Word\fR \fIshndxsrc\fR);
.fi

.LP
.nf
\fBElf_Data *\fR\fBgelf_xlatetof\fR(\fBElf *\fR\fIelf\fR, \fBElf_Data *\fR\fIdst\fR, \fBconst Elf_Data *\fR\fIsrc\fR,
     \fBunsigned\fR \fIencode\fR);
.fi

.LP
.nf
\fBElf_Data *\fR\fBgelf_xlatetom\fR(\fBElf *\fR\fIelf\fR, \fBElf_Data *\fR\fIdst\fR, \fBconst Elf_Data *\fR\fIsrc\fR,
     \fBunsigned\fR \fIencode\fR);
.fi

.SH DESCRIPTION
.sp
.LP
\fBGElf\fR is a generic, \fBELF\fR class-independent \fBAPI\fR for manipulating
\fBELF\fR object files. \fBGElf\fR provides a single, common interface for
handling 32-bit and 64-bit \fBELF\fR format object files. \fBGElf\fR is a
translation layer between the application and the class-dependent parts of the
\fBELF\fR library. Thus, the application can use \fBGElf\fR, which in turn,
will call the corresponding \fBelf32_\fR or \fBelf64_\fR functions on behalf of
the application. The data structures returned are all large enough to hold
32-bit and 64-bit data.
.sp
.LP
\fBGElf\fR provides a simple, class-independent layer of indirection over the
class-dependent \fBELF32\fR and \fBELF64\fR \fBAPI\fR's. \fBGElf\fR is
stateless, and may be used along side the \fBELF32\fR and \fBELF64\fR
\fBAPI\fR's.
.sp
.LP
\fBGElf\fR always returns a copy of the underlying \fBELF32\fR or \fBELF64\fR
structure, and therefore the programming practice of using the address of an
\fBELF\fR header as the base offset for the \fBELF\fR's mapping into memory
should be avoided. Also, data accessed by type-casting the \fBElf_Data\fR
buffer to a class-dependent type and treating it like an array, for example, a
symbol table, will not work under \fBGElf\fR, and the \fBgelf_get\fR functions
must be used instead. See the EXAMPLE section.
.sp
.LP
Programs that create or modify \fBELF\fR files using \fBlibelf\fR(3LIB) need to
perform an extra step when using \fBGElf\fR. Modifications to \fBGElf\fR values
must be explicitly flushed to the underlying \fBELF32\fR or \fBELF64\fR
structures by way of the \fBgelf_update_\fR interfaces. Use of \fBelf_update\fR
or \fBelf_flagelf\fR and the like remains the same.
.sp
.LP
The sizes of versioning structures remain the same between \fBELF32\fR and
\fBELF64\fR. The \fBGElf\fR \fBAPI\fR only defines types for versioning, rather
than a functional \fBAPI\fR. The processing of versioning information will stay
the same in the \fBGElf\fR environment as it was in the class-dependent
\fBELF\fR environment.
.SS "List of Functions"
.sp
.ne 2
.na
\fB\fBgelf_checksum()\fR\fR
.ad
.RS 26n
An analog to \fBelf32_checksum\fR(3ELF) and \fBelf64_checksum\fR(3ELF).
.RE

.sp
.ne 2
.na
\fB\fBgelf_fsize()\fR\fR
.ad
.RS 26n
An analog to \fBelf32_fsize\fR(3ELF) and \fBelf64_fsize\fR(3ELF).
.RE

.sp
.ne 2
.na
\fB\fBgelf_getcap()\fR\fR
.ad
.RS 26n
Retrieves the \fBElf32_Cap\fR or \fBElf64_Cap\fR information from the
capability table at the given index. \fBdst\fR points to the location where the
\fBGElf_Cap\fR capability entry is stored.
.RE

.sp
.ne 2
.na
\fB\fBgelf_getclass()\fR\fR
.ad
.RS 26n
Returns one of the constants \fBELFCLASS32\fR, \fBELFCLASS64\fR or
\fBELFCLASSNONE\fR.
.RE

.sp
.ne 2
.na
\fB\fBgelf_getdyn()\fR\fR
.ad
.RS 26n
Retrieves the \fBElf32_Dyn\fR or \fBElf64_Dyn\fR information from the dynamic
table at the given index. \fBdst\fR points to the location where the
\fBGElf_Dyn\fR dynamic entry is stored.
.RE

.sp
.ne 2
.na
\fB\fBgelf_getehdr()\fR\fR
.ad
.RS 26n
An analog to \fBelf32_getehdr\fR(3ELF) and \fBelf64_getehdr\fR(3ELF). \fBdst\fR
points to the location where the \fBGElf_Ehdr\fR header is stored.
.RE

.sp
.ne 2
.na
\fB\fBgelf_getmove()\fR\fR
.ad
.RS 26n
Retrieves the \fBElf32_Move\fR or \fBElf64_Move\fR information from the move
table at the given index. \fBdst\fR points to the location where the
\fBGElf_Move\fR move entry is stored.
.RE

.sp
.ne 2
.na
\fB\fBgelf_getphdr()\fR\fR
.ad
.RS 26n
An analog to \fBelf32_getphdr\fR(3ELF) and \fBelf64_getphdr\fR(3ELF). \fBdst\fR
points to the location where the \fBGElf_Phdr\fR program header is stored.
.RE

.sp
.ne 2
.na
\fB\fBgelf_getrel()\fR\fR
.ad
.RS 26n
Retrieves the \fBElf32_Rel\fR or \fBElf64_Rel\fR information from the
relocation table at the given index. \fBdst\fR points to the location where the
\fBGElf_Rel\fR relocation entry is stored.
.RE

.sp
.ne 2
.na
\fB\fBgelf_getrela()\fR\fR
.ad
.RS 26n
Retrieves the \fBElf32_Rela\fR or \fBElf64_Rela\fR information from the
relocation table at the given index. \fBdst\fR points to the location where the
\fBGElf_Rela\fR relocation entry is stored.
.RE

.sp
.ne 2
.na
\fB\fBgelf_getshdr()\fR\fR
.ad
.RS 26n
An analog to \fBelf32_getshdr\fR(3ELF) and \fBelf64_getshdr\fR(3ELF). \fBdst\fR
points to the location where the \fBGElf_Shdr\fR section header is stored.
.RE

.sp
.ne 2
.na
\fB\fBgelf_getsym()\fR\fR
.ad
.RS 26n
Retrieves the \fBElf32_Sym\fR or \fBElf64_Sym\fR information from the symbol
table at the given index. \fBdst\fR points to the location where the
\fBGElf_Sym\fR symbol entry is stored.
.RE

.sp
.ne 2
.na
\fB\fBgelf_getsyminfo()\fR\fR
.ad
.RS 26n
Retrieves the \fBElf32_Syminfo\fR or \fBElf64_Syminfo\fR information from the
relocation table at the given index. \fBdst\fR points to the location where the
\fBGElf_Syminfo\fR symbol information entry is stored.
.RE

.sp
.ne 2
.na
\fB\fBgelf_getsymshndx()\fR\fR
.ad
.RS 26n
Provides an extension to \fBgelf_getsym()\fR that retrieves the \fBElf32_Sym\fR
or \fBElf64_Sym\fR information, and the section index from the symbol table at
the given index \fIndx\fR.
.sp
The symbols section index is typically recorded in the \fBst_shndx\fR field of
the symbols structure. However, a file that requires \fBELF\fR Extended
Sections may record an \fBst_shndx\fR of \fBSHN_XINDEX\fR indicating that the
section index must be obtained from an associated \fBSHT_SYMTAB_SHNDX\fR
section entry. If \fIxshndx\fR and \fIshndxdata\fR are non-null, the value
recorded at index \fIndx\fR of the \fBSHT_SYMTAB_SHNDX\fR table pointed to by
\fIshndxdata\fR is returned in \fIxshndx\fR. See USAGE.
.RE

.sp
.ne 2
.na
\fB\fBgelf_newehdr()\fR\fR
.ad
.RS 26n
An analog to \fBelf32_newehdr\fR(3ELF) and \fBelf64_newehdr\fR(3ELF).
.RE

.sp
.ne 2
.na
\fB\fBgelf_newphdr()\fR\fR
.ad
.RS 26n
An analog to \fBelf32_newphdr\fR(3ELF) and \fBelf64_newphdr\fR(3ELF).
.RE

.sp
.ne 2
.na
\fB\fBgelf_update_cap()\fR\fR
.ad
.RS 26n
Copies the \fBGElf_Cap\fR information back into the underlying \fBElf32_Cap\fR
or \fBElf64_Cap\fR structure at the given index.
.RE

.sp
.ne 2
.na
\fB\fBgelf_update_dyn()\fR\fR
.ad
.RS 26n
Copies the \fBGElf_Dyn\fR information back into the underlying \fBElf32_Dyn\fR
or \fBElf64_Dyn\fR structure at the given index.
.RE

.sp
.ne 2
.na
\fB\fBgelf_update_ehdr()\fR\fR
.ad
.RS 26n
Copies the contents of the \fBGElf_Ehdr\fR \fBELF\fR header to the underlying
\fBElf32_Ehdr\fR or \fBElf64_Ehdr\fR structure.
.RE

.sp
.ne 2
.na
\fB\fBgelf_update_move()\fR\fR
.ad
.RS 26n
Copies the \fBGElf_Move\fR information back into the underlying
\fBElf32_Move\fR or \fBElf64_Move\fR structure at the given index.
.RE

.sp
.ne 2
.na
\fB\fBgelf_update_phdr()\fR\fR
.ad
.RS 26n
Copies of the contents of \fBGElf_Phdr\fR program header to underlying the
\fBElf32_Phdr\fR or \fBElf64_Phdr\fR structure.
.RE

.sp
.ne 2
.na
\fB\fBgelf_update_rel()\fR\fR
.ad
.RS 26n
Copies the \fBGElf_Rel\fR information back into the underlying \fBElf32_Rel\fR
or \fBElf64_Rel\fR structure at the given index.
.RE

.sp
.ne 2
.na
\fB\fBgelf_update_rela()\fR\fR
.ad
.RS 26n
Copies the \fBGElf_Rela\fR information back into the underlying
\fBElf32_Rela\fR or \fBElf64_Rela\fR structure at the given index.
.RE

.sp
.ne 2
.na
\fB\fBgelf_update_shdr()\fR\fR
.ad
.RS 26n
Copies of the contents of \fBGElf_Shdr\fR section header to underlying the
\fBElf32_Shdr\fR or \fBElf64_Shdr\fR structure.
.RE

.sp
.ne 2
.na
\fB\fBgelf_update_sym()\fR\fR
.ad
.RS 26n
Copies the \fBGElf_Sym\fR information back into the underlying \fBElf32_Sym\fR
or \fBElf64_Sym\fR structure at the given index.
.RE

.sp
.ne 2
.na
\fB\fBgelf_update_syminfo()\fR\fR
.ad
.RS 26n
Copies the \fBGElf_Syminfo\fR information back into the underlying
\fBElf32_Syminfo\fR or \fBElf64_Syminfo\fR structure at the given index.
.RE

.sp
.ne 2
.na
\fB\fBgelf_update_symshndx()\fR\fR
.ad
.RS 26n
Provides an extension to \fBgelf_update_sym()\fR that copies the \fBGElf_Sym\fR
information back into the \fBElf32_Sym\fR or \fBElf64_Sym\fR structure at the
given index \fIndx\fR, and copies the extended \fIxshndx\fR section index into
the \fBElf32_Word\fR at the given index \fIndx\fR in the buffer described by
\fBshndxdata\fR. See USAGE.
.RE

.sp
.ne 2
.na
\fB\fBgelf_xlatetof()\fR\fR
.ad
.RS 26n
An analog to \fBelf32_xlatetof\fR(3ELF) and \fBelf64_xlatetof\fR(3ELF)
.RE

.sp
.ne 2
.na
\fB\fBgelf_xlatetom()\fR\fR
.ad
.RS 26n
An analog to \fBelf32_xlatetom\fR(3ELF) and \fBelf64_xlatetom\fR(3ELF)
.RE

.SH RETURN VALUES
.sp
.LP
Upon failure, all \fBGElf\fR functions return \fB0\fR and set \fIelf_errno\fR.
See \fBelf_errno\fR(3ELF)
.SH EXAMPLES
.LP
\fBExample 1 \fRPrinting the ELF Symbol Table
.sp
.in +2
.nf
#include <stdio.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <libelf.h>
#include <gelf.h>

void
main(int argc, char **argv)
{
    Elf         *elf;
    Elf_Scn     *scn = NULL;
    GElf_Shdr   shdr;
    Elf_Data    *data;
    int         fd, ii, count;

    elf_version(EV_CURRENT);

    fd = open(argv[1], O_RDONLY);
    elf = elf_begin(fd, ELF_C_READ, NULL);

    while ((scn = elf_nextscn(elf, scn)) != NULL) {
        gelf_getshdr(scn, &shdr);
        if (shdr.sh_type == SHT_SYMTAB) {
            /* found a symbol table, go print it. */
            break;
        }
    }

    data = elf_getdata(scn, NULL);
    count = shdr.sh_size / shdr.sh_entsize;

    /* print the symbol names */
    for (ii = 0; ii < count; ++ii) {
        GElf_Sym sym;
        gelf_getsym(data, ii, &sym);
        printf("%s\en", elf_strptr(elf, shdr.sh_link, sym.st_name));
    }
    elf_end(elf);
    close(fd);
}
.fi
.in -2

.SH USAGE
.sp
.LP
ELF Extended Sections are employed to allow an ELF file to contain more than
\fB0xff00\fR (\fBSHN_LORESERVE\fR) section. See the \fILinker and Libraries
Guide\fR for more information.
.SH FILES
.sp
.ne 2
.na
\fB\fB/lib/libelf.so.1\fR\fR
.ad
.RS 23n
shared object
.RE

.sp
.ne 2
.na
\fB\fB/lib/64/libelf.so.1\fR\fR
.ad
.RS 23n
64-bit shared object
.RE

.SH ATTRIBUTES
.sp
.LP
See \fBattributes\fR(5) for descriptions of the following attributes:
.sp

.sp
.TS
box;
c | c
l | l .
ATTRIBUTE TYPE	ATTRIBUTE VALUE
_
Interface Stability	Stable
_
MT Level	MT-Safe
.TE

.SH SEE ALSO
.sp
.LP
\fBelf\fR(3ELF), \fBelf32_checksum\fR(3ELF), \fBelf32_fsize\fR(3ELF),
\fBelf32_getehdr\fR(3ELF), \fBelf32_newehdr\fR(3ELF),
\fBelf32_getphdr\fR(3ELF), \fBelf32_newphdr\fR(3ELF),
\fBelf32_getshdr\fR(3ELF), \fBelf32_xlatetof\fR(3ELF),
\fBelf32_xlatetom\fR(3ELF), \fBelf_errno\fR(3ELF), \fBlibelf\fR(3LIB),
\fBattributes\fR(5)
.sp
.LP
\fILinker and Libraries Guide\fR