Initial import from FreeBSD RELENG_4:
[dragonfly.git] / contrib / gcc / config / interix.h
1 /* Operating system specific defines to be used when targeting GCC for
2    Interix
3    Copyright (C) 1994, 1995, 1999 Free Software Foundation, Inc.
4    Donn Terry, Softway Systems, Inc. (donn@softway.com)
5    Modified from code
6       Contributed by Douglas B. Rupp (drupp@cs.washington.edu).
7
8 This file is part of GNU CC.
9
10 GNU CC is free software; you can redistribute it and/or modify
11 it under the terms of the GNU General Public License as published by
12 the Free Software Foundation; either version 2, or (at your option)
13 any later version.
14
15 GNU CC is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18 GNU General Public License for more details.
19
20 You should have received a copy of the GNU General Public License
21 along with GNU CC; see the file COPYING.  If not, write to
22 the Free Software Foundation, 59 Temple Place - Suite 330,
23 Boston, MA 02111-1307, USA.  */
24
25 #define TARGET_MEM_FUNCTIONS
26
27 /* POSIX/Uni-thread only for now.  Look at the winnt version
28 for windows/multi thread */
29
30 /* We need multiple -lc -lcpsx because they mutually refer;
31    that should go away someday */
32
33 #undef LIB_SPEC
34 #define LIB_SPEC "\
35  %{!shared:%{!dynamic:-lc -lcpsx -lc -lcpsx %$INTERIX_ROOT/usr/lib/psxdll.a \
36  %$INTERIX_ROOT/usr/lib/psxdll2.a \
37  }} \
38  %{!G:%{!dynamic:-lc -lcpsx -lc -lcpsx %$INTERIX_ROOT/usr/lib/psxdll.a \
39  %$INTERIX_ROOT/usr/lib/psxdll2.a \
40  }} \
41  %{dynamic:-lc %$INTERIX_ROOT/usr/lib/psxdll.a \
42  %$INTERIX_ROOT/usr/lib/psxdll2.a \
43  } \
44  %{v}"
45
46 #undef LINK_SPEC
47 #define LINK_SPEC "%{!shared:-stack 0x400000,0x10000} \
48                    -subsystem posix \
49                    %{g} \
50                    %{dynamic:-Bdynamic} \
51                    %{static:-Bstatic} \
52                    %{shared:--shared -Bdynamic} \
53                    %{G:--shared -Bdynamic} \
54                    %{symbolic:--shared -Bsymbolic -Bdynamic} \
55                    %{soname*:--soname %*} \
56                    %{rpath*:--rpath %*} \
57                    "
58
59 #undef STARTFILE_SPEC
60 #define STARTFILE_SPEC  \
61   "%{!shared:%{pg:gcrt0%O%s}%{!pg:%{p:mcrt0%O%s}%{!p:crt0%O%s}}} %{shared:crti%O%s}"
62
63 #undef WORD_SWITCH_TAKES_ARG
64 #define WORD_SWITCH_TAKES_ARG(STR)                                      \
65  ((DEFAULT_WORD_SWITCH_TAKES_ARG (STR)                                  \
66  || !strcmp(STR, "rpath"))                                              \
67   && strcmp (STR, "Tdata") && strcmp (STR, "Ttext")                     \
68   && strcmp (STR, "Tbss"))
69
70
71 #if 0   
72 /* don't do this until we can sort out the default path issues. MK */
73 #undef STANDARD_EXEC_PREFIX
74 #define STANDARD_EXEC_PREFIX ""
75
76 #undef STANDARD_STARTFILE_PREFIX
77 #define STANDARD_STARTFILE_PREFIX ""
78
79 #undef TOOLDIR_BASE_PREFIX
80 #define TOOLDIR_BASE_PREFIX ""
81
82 #endif /* 0 */
83
84 #undef STDC_VALUE
85 #define STDC_VALUE 0
86
87 #define HANDLE_SYSV_PRAGMA
88 #undef HANDLE_PRAGMA_WEAK  /* until the link format can handle it */
89
90 /* Names to predefine in the preprocessor for this target machine.  */
91
92 #define DBX_DEBUGGING_INFO
93 #define SDB_DEBUGGING_INFO
94 #undef PREFERRED_DEBUGGING_TYPE
95 #define PREFERRED_DEBUGGING_TYPE DBX_DEBUG
96
97
98 /* TARGET_DEFAULT from configure */
99
100 #undef WCHAR_TYPE
101 #undef WCHAR_TYPE_SIZE
102 #define WCHAR_UNSIGNED 1
103 #define WCHAR_TYPE "short unsigned int"
104 #define WCHAR_TYPE_SIZE 16
105
106 /* For the sake of libgcc2.c, indicate target supports atexit.  */
107 #define HAVE_ATEXIT