]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - contrib/gcc/config/s390/freebsd.h
regen src.conf.5 after r358454, GCC 4.2.1 retirement
[FreeBSD/FreeBSD.git] / contrib / gcc / config / s390 / freebsd.h
1 /* Definitions for FreeBSD for S/390.
2    Copyright (C) 1999, 2000, 2001, 2002, 2004, 2005, 2006
3    Free Software Foundation, Inc.
4    Contributed by Hartmut Penner (hpenner@de.ibm.com) and
5                   Ulrich Weigand (uweigand@de.ibm.com).
6
7 This file is part of GCC.
8
9 GCC is free software; you can redistribute it and/or modify it under
10 the terms of the GNU General Public License as published by the Free
11 Software Foundation; either version 2, or (at your option) any later
12 version.
13
14 GCC is distributed in the hope that it will be useful, but WITHOUT ANY
15 WARRANTY; without even the implied warranty of MERCHANTABILITY or
16 FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
17 for more details.
18
19 You should have received a copy of the GNU General Public License
20 along with GCC; see the file COPYING.  If not, write to the Free
21 Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA
22 02110-1301, USA.  */
23
24 #ifndef _CONFIG_S390_FREEBSD_H
25 #define _CONFIG_S390_FREEBSD_H
26
27 /* Target specific version string.  */
28
29 #ifdef DEFAULT_TARGET_64BIT
30 #undef  TARGET_VERSION
31 #define TARGET_VERSION fprintf (stderr, " (FreeBSD for zSeries)");
32 #else
33 #undef  TARGET_VERSION
34 #define TARGET_VERSION fprintf (stderr, " (FreeBSD for S/390)");
35 #endif
36
37
38 /* Target specific type definitions.  */
39
40 /* ??? Do we really want long as size_t on 31-bit?  */
41 /* Answer is yes for FreeBSD. */
42 #undef  SIZE_TYPE
43 #define SIZE_TYPE (TARGET_64BIT ? "long unsigned int" : "unsigned int")
44 #undef  PTRDIFF_TYPE
45 #define PTRDIFF_TYPE (TARGET_64BIT ? "long int" : "int")
46
47 #undef  WCHAR_TYPE
48 #define WCHAR_TYPE "int"
49 #undef  WCHAR_TYPE_SIZE
50 #define WCHAR_TYPE_SIZE 32
51
52 #undef DEFAULT_SIGNED_CHAR
53 #define DEFAULT_SIGNED_CHAR 1
54
55 /* Target specific assembler settings.  */
56
57 #undef  ASM_SPEC
58 #define ASM_SPEC "%{m31&m64}%{mesa&mzarch}%{march=*}"
59
60
61 /* Target specific linker settings.  */
62
63 #ifdef DEFAULT_TARGET_64BIT
64 #define MULTILIB_DEFAULTS { "m64" }
65 #else
66 #define MULTILIB_DEFAULTS { "m31" }
67 #endif
68
69 #define GLIBC_DYNAMIC_LINKER32 "/lib/ld.so.1"
70 #define GLIBC_DYNAMIC_LINKER64 "/lib/ld64.so.1"
71
72 #undef  LINK_SPEC
73 #define LINK_SPEC \
74   "%{m31:-m elf_s390}%{m64:-m elf64_s390} \
75    %{shared:-shared} \
76    %{!shared: \
77       %{static:-static} \
78       %{!static: \
79         %{rdynamic:-export-dynamic} \
80         %{!dynamic-linker: \
81           %{m31:-dynamic-linker " LINUX_DYNAMIC_LINKER32 "} \
82           %{m64:-dynamic-linker " LINUX_DYNAMIC_LINKER64 "}}}}"
83
84 #define CPP_SPEC "%{posix:-D_POSIX_SOURCE} %{pthread:-D_REENTRANT}"
85
86 #define TARGET_ASM_FILE_END file_end_indicate_exec_stack
87
88 #define MD_UNWIND_SUPPORT "config/s390/freebsd-unwind.h"
89
90 #ifdef TARGET_LIBC_PROVIDES_SSP
91 /* s390 glibc provides __stack_chk_guard in 0x14(tp),
92    s390x glibc provides it at 0x28(tp).  */
93 #define TARGET_THREAD_SSP_OFFSET        (TARGET_64BIT ? 0x28 : 0x14)
94 #endif
95
96 /* Define if long doubles should be mangled as 'g'.  */
97 #define TARGET_ALTERNATE_LONG_DOUBLE_MANGLING
98
99 /* Override the default comment-starter of "/APP" from unix.h.  */
100 #undef  ASM_APP_ON
101 #define ASM_APP_ON      "#APP\n"
102 #undef  ASM_APP_OFF
103 #define ASM_APP_OFF     "#NO_APP\n"
104
105 #endif