OSDN Git Service

* flags.h (g_switch_value): Change to an unsigned
[pf3gnuchains/gcc-fork.git] / gcc / config / alpha / openbsd.h
1 /* Configuration file for an alpha OpenBSD target.
2    Copyright (C) 1999 Free Software Foundation, Inc.
3
4 This file is part of GNU CC.
5
6 GNU CC 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 2, or (at your option)
9 any later version.
10
11 GNU CC 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 GNU CC; see the file COPYING.  If not, write to
18 the Free Software Foundation, 59 Temple Place - Suite 330,
19 Boston, MA 02111-1307, USA.  */
20
21 /* We settle for little endian for now.  */
22 #define TARGET_ENDIAN_DEFAULT 0
23
24 #define OBSD_NO_DYNAMIC_LIBRARIES
25 #define OBSD_HAS_DECLARE_FUNCTION_NAME
26 #define OBSD_HAS_DECLARE_FUNCTION_SIZE
27 #define OBSD_HAS_DECLARE_OBJECT
28
29 /* alpha ecoff supports only weak aliases, see below.  */
30 #define ASM_WEAKEN_LABEL(FILE,NAME) ASM_OUTPUT_WEAK_ALIAS (FILE,NAME,0)
31
32 #include <openbsd.h>
33
34 /* Controlling the compilation driver.  */
35
36 /* alpha needs __start.  */
37 #undef LINK_SPEC
38 #define LINK_SPEC \
39   "%{!nostdlib:%{!r*:%{!e*:-e __start}}} -dc -dp %{assert*}"
40
41 /* run-time target specifications */
42 #define TARGET_OS_CPP_BUILTINS()                \
43     do {                                        \
44         builtin_define ("__OpenBSD__");         \
45         builtin_define ("__ANSI_COMPAT");       \
46         builtin_define ("__unix__");            \
47         builtin_assert ("system=unix");         \
48     } while (0)
49
50 /* Layout of source language data types.  */
51
52 /* This must agree with <machine/ansi.h> */
53 #undef SIZE_TYPE
54 #define SIZE_TYPE "long unsigned int"
55
56 #undef PTRDIFF_TYPE
57 #define PTRDIFF_TYPE "long int"
58
59 #undef WCHAR_TYPE
60 #define WCHAR_TYPE "int"
61
62 #undef WCHAR_TYPE_SIZE
63 #define WCHAR_TYPE_SIZE 32
64
65 \f
66 #undef PREFERRED_DEBUGGING_TYPE
67 #define PREFERRED_DEBUGGING_TYPE DBX_DEBUG
68
69 #define LOCAL_LABEL_PREFIX      "."
70
71 /* We don't have an init section yet.  */
72 #undef HAS_INIT_SECTION
73
74 /* collect2 support (assembler format: macros for initialization).  */
75
76 /* Don't tell collect2 we use COFF as we don't have (yet ?) a dynamic ld
77    library with the proper functions to handle this -> collect2 will
78    default to using nm.  */
79 #undef OBJECT_FORMAT_COFF
80 #undef EXTENDED_COFF
81
82 /* Assembler format: exception region output.  */
83
84 /* All configurations that don't use elf must be explicit about not using
85    dwarf unwind information. egcs doesn't try too hard to check internal
86    configuration files...  */
87 #ifdef INCOMING_RETURN_ADDR_RTX
88 #undef DWARF2_UNWIND_INFO
89 #define DWARF2_UNWIND_INFO 0
90 #endif
91
92 /* Assembler format: file framework.  */
93
94 /* Taken from alpha/osf.h. This used to be common to all alpha
95    configurations, but elf has departed from it.
96    Check alpha/alpha.h, alpha/osf.h for it when egcs is upgraded.  */
97 #ifndef ASM_FILE_START
98 #define ASM_FILE_START(FILE)                                    \
99 {                                                               \
100   alpha_write_verstamp (FILE);                                  \
101   fprintf (FILE, "\t.set noreorder\n");                         \
102   fprintf (FILE, "\t.set volatile\n");                          \
103   fprintf (FILE, "\t.set noat\n");                              \
104   if (TARGET_SUPPORT_ARCH)                                      \
105     fprintf (FILE, "\t.arch %s\n",                              \
106              TARGET_CPU_EV6 ? "ev6"                             \
107              : (TARGET_CPU_EV5                                  \
108                 ? (TARGET_MAX ? "pca56" : TARGET_BWX ? "ev56" : "ev5") \
109                 : "ev4"));                                      \
110                                                                 \
111   ASM_OUTPUT_SOURCE_FILENAME (FILE, main_input_filename);       \
112 }
113 #endif
114
115 /* Assembler format: label output.  */
116
117 #define ASM_OUTPUT_WEAK_ALIAS(FILE,NAME,VALUE)  \
118  do {                                           \
119   fputs ("\t.weakext\t", FILE);                 \
120   assemble_name (FILE, NAME);                   \
121   if (VALUE)                                    \
122     {                                           \
123       fputs (" , ", FILE);                      \
124       assemble_name (FILE, VALUE);              \
125     }                                           \
126   fputc ('\n', FILE);                           \
127  } while (0)
128
129