]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - gas/config/obj-som.h
* config/sh/tm-sh.h (BELIEVE_PCC_PROMOTION): Define, so that
[thirdparty/binutils-gdb.git] / gas / config / obj-som.h
1 /* SOM object file format.
2 Copyright (C) 1993 Free Software Foundation, Inc.
3
4 This file is part of GAS, the GNU Assembler.
5
6 GAS is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 1, or (at your option)
9 any later version.
10
11 GAS is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with GAS; see the file COPYING. If not, write to
18 the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
19
20 Written by the Center for Software Science at the University of Utah
21 and by Cygnus Support. */
22
23 #ifndef _OBJ_SOM_H
24 #define _OBJ_SOM_H
25
26 #define OBJ_SOM 1
27
28 #include <bfd.h>
29 #include "../bfd/som.h"
30 #include "targ-cpu.h"
31
32 #ifndef FALSE
33 #define FALSE 0
34 #define TRUE !FALSE
35 #endif
36
37 /* should be conditional on address size! */
38 #define som_symbol(asymbol) ((som_symbol_type *)(&(asymbol)->the_bfd))
39
40 #define S_SET_OTHER(S,V) (som_symbol((S)->bsym)->other = (V))
41 #define S_SET_TYPE(S,T) (som_symbol((S)->bsym)->type = (T))
42 #define S_SET_DESC(S,D) (som_symbol((S)->bsym)->desc = (D))
43 #define S_GET_OTHER(S) (som_symbol((S)->bsym)->other)
44 #define S_GET_TYPE(S) (som_symbol((S)->bsym)->type)
45 #define S_GET_DESC(S) (som_symbol((S)->bsym)->desc)
46
47 #define S_SET_SIZE(S,V) (som_symbol((S)->bsym)->internal_som_sym.st_size)
48
49 extern void som_file_symbol PARAMS ((char *));
50 extern void obj_som_version PARAMS ((int));
51 extern void obj_som_init_stab_section PARAMS ((segT));
52
53 #define obj_symbol_new_hook(s) {;}
54 #define obj_read_begin_hook() {;}
55
56 /* SOM has several attributes for spaces/subspaces which can not
57 be easily expressed in BFD. We use these macros to trigger calls
58 into the SOM BFD backend to set these attributes. */
59 #define obj_set_section_attributes bfd_som_set_section_attributes
60 #define obj_set_subsection_attributes bfd_som_set_subsection_attributes
61
62 /* Likewise for symbol types. */
63 #define obj_set_symbol_type bfd_som_set_symbol_type
64
65 /* This is the trigger for calling a BFD routine to attach unwind
66 information to a function symbol. */
67 #define obj_attach_unwind_info bfd_som_attach_unwind_info
68
69 /* Stabs go in a separate sections. GDB expects to find them in sections
70 with the names $GDB_SYMBOLS$ and $GDB_STRINGS$ rather than .stab and
71 .stabstr. */
72 #define SEPARATE_STAB_SECTIONS
73 #define STAB_SECTION_NAME "$GDB_SYMBOLS$"
74 #define STAB_STRING_SECTION_NAME "$GDB_STRINGS$"
75
76 /* We use INIT_STAB_SECTION to record the space/subspace relationships
77 for the various debugging sections. */
78 #define INIT_STAB_SECTION(seg) obj_som_init_stab_section (seg)
79
80 /* We'll be updating the magic 1st stab entry once the entire assembly
81 fail has been processed. */
82 #define obj_frob_file() som_frob_file()
83
84 #endif /* _OBJ_SOM_H */