xref: /openbsd-src/gnu/usr.bin/binutils-2.17/include/coff/we32k.h (revision 3d8817e467ea46cf4772788d6804dd293abfb01a)
1*3d8817e4Smiod /* coff information for we32k
2*3d8817e4Smiod 
3*3d8817e4Smiod    Copyright 2001 Free Software Foundation, Inc.
4*3d8817e4Smiod 
5*3d8817e4Smiod    This program is free software; you can redistribute it and/or modify
6*3d8817e4Smiod    it under the terms of the GNU General Public License as published by
7*3d8817e4Smiod    the Free Software Foundation; either version 2 of the License, or
8*3d8817e4Smiod    (at your option) any later version.
9*3d8817e4Smiod 
10*3d8817e4Smiod    This program is distributed in the hope that it will be useful,
11*3d8817e4Smiod    but WITHOUT ANY WARRANTY; without even the implied warranty of
12*3d8817e4Smiod    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13*3d8817e4Smiod    GNU General Public License for more details.
14*3d8817e4Smiod 
15*3d8817e4Smiod    You should have received a copy of the GNU General Public License
16*3d8817e4Smiod    along with this program; if not, write to the Free Software
17*3d8817e4Smiod    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.  */
18*3d8817e4Smiod #define L_LNNO_SIZE 2
19*3d8817e4Smiod #include "coff/external.h"
20*3d8817e4Smiod 
21*3d8817e4Smiod /* Bits for f_flags:
22*3d8817e4Smiod  	F_RELFLG	relocation info stripped from file
23*3d8817e4Smiod  	F_EXEC		file is executable (no unresolved external references)
24*3d8817e4Smiod  	F_LNNO		line numbers stripped from file
25*3d8817e4Smiod  	F_LSYMS		local symbols stripped from file
26*3d8817e4Smiod  	F_AR32WR	file has byte ordering of an AR32WR machine (e.g. vax).  */
27*3d8817e4Smiod 
28*3d8817e4Smiod #define F_RELFLG	(0x0001)
29*3d8817e4Smiod #define F_EXEC		(0x0002)
30*3d8817e4Smiod #define F_LNNO		(0x0004)
31*3d8817e4Smiod #define F_LSYMS		(0x0008)
32*3d8817e4Smiod #define	F_BM32B		(0020000)
33*3d8817e4Smiod #define	F_BM32MAU	(0040000)
34*3d8817e4Smiod 
35*3d8817e4Smiod #define	WE32KMAGIC	0x170	/* we32k sans transfer vector */
36*3d8817e4Smiod #define FBOMAGIC	0x170	/* we32k sans transfer vector */
37*3d8817e4Smiod #define MTVMAGIC	0x171	/* we32k with transfer vector */
38*3d8817e4Smiod #define RBOMAGIC	0x172	/* reserved */
39*3d8817e4Smiod #define WE32KBADMAG(x) (   ((x).f_magic != WE32KMAGIC) \
40*3d8817e4Smiod 			&& ((x).f_magic != FBOMAGIC) \
41*3d8817e4Smiod 			&& ((x).f_magic != RBOMAGIC) \
42*3d8817e4Smiod 			&& ((x).f_magic != MTVMAGIC))
43*3d8817e4Smiod 
44*3d8817e4Smiod /* More names of "special" sections.  */
45*3d8817e4Smiod #define _TV	".tv"
46*3d8817e4Smiod #define _INIT	".init"
47*3d8817e4Smiod #define _FINI	".fini"
48*3d8817e4Smiod 
49*3d8817e4Smiod /********************** RELOCATION DIRECTIVES **********************/
50*3d8817e4Smiod 
51*3d8817e4Smiod struct external_reloc
52*3d8817e4Smiod {
53*3d8817e4Smiod   char r_vaddr[4];
54*3d8817e4Smiod   char r_symndx[4];
55*3d8817e4Smiod   char r_type[2];
56*3d8817e4Smiod };
57*3d8817e4Smiod 
58*3d8817e4Smiod #define RELOC struct external_reloc
59*3d8817e4Smiod #define RELSZ 10
60*3d8817e4Smiod 
61