1*3d8817e4Smiod /* coff information for Windows CE with MIPS VR4111 2*3d8817e4Smiod 3*3d8817e4Smiod Copyright 2000 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 19*3d8817e4Smiod #define L_LNNO_SIZE 2 20*3d8817e4Smiod #define INCLUDE_COMDAT_FIELDS_IN_AUXENT 21*3d8817e4Smiod #include "coff/external.h" 22*3d8817e4Smiod 23*3d8817e4Smiod #define MIPS_ARCH_MAGIC_WINCE 0x0166 /* Windows CE - little endian */ 24*3d8817e4Smiod #define MIPS_PE_MAGIC 0x010b 25*3d8817e4Smiod 26*3d8817e4Smiod #define MIPSBADMAG(x) ((x).f_magic != MIPS_ARCH_MAGIC_WINCE) 27*3d8817e4Smiod 28*3d8817e4Smiod /* define some NT default values */ 29*3d8817e4Smiod /* #define NT_IMAGE_BASE 0x400000 moved to internal.h */ 30*3d8817e4Smiod #define NT_SECTION_ALIGNMENT 0x1000 31*3d8817e4Smiod #define NT_FILE_ALIGNMENT 0x200 32*3d8817e4Smiod #define NT_DEF_RESERVE 0x100000 33*3d8817e4Smiod #define NT_DEF_COMMIT 0x1000 34*3d8817e4Smiod 35*3d8817e4Smiod /********************** RELOCATION DIRECTIVES **********************/ 36*3d8817e4Smiod 37*3d8817e4Smiod /* The external reloc has an offset field, because some of the reloc 38*3d8817e4Smiod types on the h8 don't have room in the instruction for the entire 39*3d8817e4Smiod offset - eg the strange jump and high page addressing modes. */ 40*3d8817e4Smiod 41*3d8817e4Smiod struct external_reloc 42*3d8817e4Smiod { 43*3d8817e4Smiod char r_vaddr[4]; 44*3d8817e4Smiod char r_symndx[4]; 45*3d8817e4Smiod char r_type[2]; 46*3d8817e4Smiod }; 47*3d8817e4Smiod 48*3d8817e4Smiod #define RELOC struct external_reloc 49*3d8817e4Smiod #define RELSZ 10 50*3d8817e4Smiod 51*3d8817e4Smiod /* MIPS PE relocation types. */ 52*3d8817e4Smiod 53*3d8817e4Smiod #define MIPS_R_ABSOLUTE 0 /* ignored */ 54*3d8817e4Smiod #define MIPS_R_REFHALF 1 55*3d8817e4Smiod #define MIPS_R_REFWORD 2 56*3d8817e4Smiod #define MIPS_R_JMPADDR 3 57*3d8817e4Smiod #define MIPS_R_REFHI 4 /* PAIR follows */ 58*3d8817e4Smiod #define MIPS_R_REFLO 5 59*3d8817e4Smiod #define MIPS_R_GPREL 6 60*3d8817e4Smiod #define MIPS_R_LITERAL 7 /* same as GPREL */ 61*3d8817e4Smiod #define MIPS_R_SECTION 10 62*3d8817e4Smiod #define MIPS_R_SECREL 11 63*3d8817e4Smiod #define MIPS_R_SECRELLO 12 64*3d8817e4Smiod #define MIPS_R_SECRELHI 13 /* PAIR follows */ 65*3d8817e4Smiod #define MIPS_R_RVA 34 /* 0x22 */ 66*3d8817e4Smiod #define MIPS_R_PAIR 37 /* 0x25 - symndx is really a signed 16-bit addend */ 67