| 1 | /* ECOFF object file format header file. | 
|---|
| 2 | Copyright 1993, 1994, 1995, 1996, 1997, 1999, 2002 | 
|---|
| 3 | Free Software Foundation, Inc. | 
|---|
| 4 | Contributed by Cygnus Support. | 
|---|
| 5 | Written by Ian Lance Taylor <ian@cygnus.com>. | 
|---|
| 6 |  | 
|---|
| 7 | This file is part of GAS. | 
|---|
| 8 |  | 
|---|
| 9 | GAS is free software; you can redistribute it and/or modify | 
|---|
| 10 | it under the terms of the GNU General Public License as published by | 
|---|
| 11 | the Free Software Foundation; either version 2, or (at your option) | 
|---|
| 12 | any later version. | 
|---|
| 13 |  | 
|---|
| 14 | GAS is distributed in the hope that it will be useful, | 
|---|
| 15 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 
|---|
| 16 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the | 
|---|
| 17 | GNU General Public License for more details. | 
|---|
| 18 |  | 
|---|
| 19 | You should have received a copy of the GNU General Public License | 
|---|
| 20 | along with GAS; see the file COPYING.  If not, write to the Free | 
|---|
| 21 | Software Foundation, 59 Temple Place - Suite 330, Boston, MA | 
|---|
| 22 | 02111-1307, USA.  */ | 
|---|
| 23 |  | 
|---|
| 24 | #define OBJ_ECOFF 1 | 
|---|
| 25 |  | 
|---|
| 26 | /* Use the generic ECOFF debugging code.  */ | 
|---|
| 27 | #define ECOFF_DEBUGGING 1 | 
|---|
| 28 |  | 
|---|
| 29 | #define OUTPUT_FLAVOR bfd_target_ecoff_flavour | 
|---|
| 30 |  | 
|---|
| 31 | #include "targ-cpu.h" | 
|---|
| 32 |  | 
|---|
| 33 | #include "ecoff.h" | 
|---|
| 34 |  | 
|---|
| 35 | /* For each gas symbol we keep track of which file it came from, of | 
|---|
| 36 | whether we have generated an ECOFF symbol for it, and whether the | 
|---|
| 37 | symbols is undefined (this last is needed to distinguish a .extern | 
|---|
| 38 | symbols from a .comm symbol).  */ | 
|---|
| 39 |  | 
|---|
| 40 | struct ecoff_sy_obj | 
|---|
| 41 | { | 
|---|
| 42 | struct efdr *ecoff_file; | 
|---|
| 43 | struct localsym *ecoff_symbol; | 
|---|
| 44 | valueT ecoff_extern_size; | 
|---|
| 45 | }; | 
|---|
| 46 |  | 
|---|
| 47 | #define OBJ_SYMFIELD_TYPE struct ecoff_sy_obj | 
|---|
| 48 |  | 
|---|
| 49 | /* Modify the ECOFF symbol.  */ | 
|---|
| 50 | #define obj_frob_symbol(symp, punt) ecoff_frob_symbol (symp) | 
|---|
| 51 |  | 
|---|
| 52 | /* Set section VMAs and GP.  */ | 
|---|
| 53 | extern void ecoff_frob_file_before_fix PARAMS ((void)); | 
|---|
| 54 | #define obj_frob_file_before_fix() ecoff_frob_file_before_fix () | 
|---|
| 55 |  | 
|---|
| 56 | /* This is used to write the symbolic data in the format that BFD | 
|---|
| 57 | expects it.  */ | 
|---|
| 58 | extern void ecoff_frob_file PARAMS ((void)); | 
|---|
| 59 | #define obj_frob_file() ecoff_frob_file () | 
|---|
| 60 |  | 
|---|
| 61 | /* We use the ECOFF functions as our hooks.  */ | 
|---|
| 62 | #define obj_read_begin_hook ecoff_read_begin_hook | 
|---|
| 63 | #define obj_symbol_new_hook ecoff_symbol_new_hook | 
|---|
| 64 |  | 
|---|
| 65 | /* Record file switches in the ECOFF symbol table.  */ | 
|---|
| 66 | #define obj_app_file(name) ecoff_new_file (name) | 
|---|
| 67 |  | 
|---|
| 68 | /* At the moment we don't want to do any stabs processing in read.c.  */ | 
|---|
| 69 | #define OBJ_PROCESS_STAB(seg, what, string, type, other, desc) \ | 
|---|
| 70 | ecoff_stab ((seg), (what), (string), (type), (other), (desc)) | 
|---|
| 71 |  | 
|---|
| 72 | #define EMIT_SECTION_SYMBOLS            0 | 
|---|
| 73 | #define obj_sec_sym_ok_for_reloc(SEC)   1 | 
|---|
| 74 |  | 
|---|
| 75 | #define obj_ecoff_set_ext ecoff_set_ext | 
|---|
| 76 | extern void obj_ecoff_set_ext PARAMS ((symbolS *, EXTR *)); | 
|---|