annotate dynodump/_dynodump.h @ 64:a01e7a40045c r19-16-pre7

Import from CVS: tag r19-16-pre7
author cvs
date Mon, 13 Aug 2007 08:59:30 +0200
parents ac2d302a0011
children 131b0175ea99
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1 /*
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
2 * Copyright (c) 1995 by Sun Microsystems, Inc.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
3 * All rights reserved.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
4 *
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
5 * This source code is a product of Sun Microsystems, Inc. and is provided
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
6 * for unrestricted use provided that this legend is included on all tape
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
7 * media and as a part of the software program in whole or part. Users
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
8 * may copy or modify this source code without charge, but are not authorized
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
9 * to license or distribute it to anyone else except as part of a product or
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
10 * program developed by the user.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
11 *
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
12 * THIS PROGRAM CONTAINS SOURCE CODE COPYRIGHTED BY SUN MICROSYSTEMS, INC.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
13 * SUN MICROSYSTEMS, INC., MAKES NO REPRESENTATIONS ABOUT THE SUITABLITY
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
14 * OF SUCH SOURCE CODE FOR ANY PURPOSE. IT IS PROVIDED "AS IS" WITHOUT
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
15 * EXPRESS OR IMPLIED WARRANTY OF ANY KIND. SUN MICROSYSTEMS, INC. DISCLAIMS
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
16 * ALL WARRANTIES WITH REGARD TO SUCH SOURCE CODE, INCLUDING ALL IMPLIED
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
17 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
18 * NO EVENT SHALL SUN MICROSYSTEMS, INC. BE LIABLE FOR ANY SPECIAL, INDIRECT,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
19 * INCIDENTAL, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
20 * FROM USE OF SUCH SOURCE CODE, REGARDLESS OF THE THEORY OF LIABILITY.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
21 *
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
22 * This source code is provided with no support and without any obligation on
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
23 * the part of Sun Microsystems, Inc. to assist in its use, correction,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
24 * modification or enhancement.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
25 *
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
26 * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
27 * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY THIS
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
28 * SOURCE CODE OR ANY PART THEREOF.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
29 *
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
30 * Sun Microsystems, Inc.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
31 * 2550 Garcia Avenue
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
32 * Mountain View, California 94043
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
33 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
34
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
35 #pragma ident "@(#) $Id: _dynodump.h,v 1.1.1.2 1996/12/18 03:48:00 steve Exp $ - SMI"
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
36
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
37 #ifndef _DYNODUMP_DOT_H
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
38 #define _DYNODUMP_DOT_H
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
39
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
40 #include <libelf.h>
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
41 #include "machdep.h"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
42
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
43 /* General rounding macro */
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
44 #define S_ROUND(x, a) (((int)(x) + (((int)(a) ? (int)(a) : 1) - 1)) & \
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
45 ~(((int)(a) ? (int)(a) : 1) - 1))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
46
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
47 /*
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
48 * Define a cache structure that is used to retain all elf section information.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
49 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
50 typedef struct cache {
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
51 Elf_Scn *c_scn;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
52 Shdr *c_shdr;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
53 Elf_Data *c_data;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
54 char *c_name;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
55 } Cache;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
56
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
57 /*
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
58 * Define any local prototypes.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
59 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
60 extern void update_dynamic(Cache *);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
61 extern void update_reloc(Cache *, Cache *, Cache *, Cache *, Half shnum);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
62 extern void update_sym(Cache *, Cache *, Addr);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
63 extern void dynodump_uninit(void);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
64
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
65 #endif