Back to index

cell-binutils  2.17cvs20070401
powerpc.h
Go to the documentation of this file.
00001 /* Basic coff information for the PowerPC
00002    Based on coff/rs6000.h, coff/i386.h and others.
00003    
00004    Copyright 2001 Free Software Foundation, Inc.
00005 
00006    This program is free software; you can redistribute it and/or modify
00007    it under the terms of the GNU General Public License as published by
00008    the Free Software Foundation; either version 2 of the License, or
00009    (at your option) any later version.
00010    
00011    This program is distributed in the hope that it will be useful,
00012    but WITHOUT ANY WARRANTY; without even the implied warranty of
00013    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014    GNU General Public License for more details.
00015    
00016    You should have received a copy of the GNU General Public License
00017    along with this program; if not, write to the Free Software
00018    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
00019  
00020    Initial release: Kim Knuttila (krk@cygnus.com)  */
00021 #define L_LNNO_SIZE 2
00022 #define INCLUDE_COMDAT_FIELDS_IN_AUXENT
00023 #include "coff/external.h"
00024 
00025 /* Bits for f_flags:
00026        F_RELFLG      relocation info stripped from file
00027        F_EXEC        file is executable (no unresolved external references)
00028        F_LNNO        line numbers stripped from file
00029        F_LSYMS              local symbols stripped from file
00030        F_AR32WR      file has byte ordering of an AR32WR machine (e.g. vax).  */
00031 
00032 #define F_RELFLG     (0x0001)
00033 #define F_EXEC              (0x0002)
00034 #define F_LNNO              (0x0004)
00035 #define F_LSYMS             (0x0008)
00036 
00037 /* extra NT defines */
00038 #define PPCMAGIC       0760         /* peeked on aa PowerPC Windows NT box */
00039 #define DOSMAGIC       0x5a4d       /* from arm.h, i386.h */
00040 #define NT_SIGNATURE   0x00004550   /* from arm.h, i386.h */
00041 
00042 /* from winnt.h */
00043 #define IMAGE_NT_OPTIONAL_HDR_MAGIC        0x10b
00044 
00045 #define PPCBADMAG(x) ((x).f_magic != PPCMAGIC) 
00046 
00047 /********************** RELOCATION DIRECTIVES **********************/
00048 
00049 struct external_reloc
00050 {
00051   char r_vaddr[4];
00052   char r_symndx[4];
00053   char r_type[2];
00054 };
00055 
00056 #define RELOC struct external_reloc
00057 #define RELSZ 10
00058