* config/netbsd.h (TARGET_HAS_F_SETLKW): define.
[official-gcc.git] / gcc / config / alpha / netbsd.h
blob7eacce23f8c75b18b8afb213da7f34cb70326c51
1 /* Definitions of target machine for GNU compiler,
2 for Alpha NetBSD systems.
3 Copyright (C) 1998, 2002 Free Software Foundation, Inc.
5 This file is part of GNU CC.
7 GNU CC is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2, or (at your option)
10 any later version.
12 GNU CC is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with GNU CC; see the file COPYING. If not, write to
19 the Free Software Foundation, 59 Temple Place - Suite 330,
20 Boston, MA 02111-1307, USA. */
22 #undef TARGET_DEFAULT
23 #define TARGET_DEFAULT (MASK_FP | MASK_FPREGS | MASK_GAS)
25 #undef CPP_PREDEFINES
26 #define CPP_PREDEFINES \
27 "-D__NetBSD__ -D__ELF__ -Asystem=unix -Asystem=NetBSD"
30 /* Show that we need a GP when profiling. */
31 #undef TARGET_PROFILING_NEEDS_GP
32 #define TARGET_PROFILING_NEEDS_GP 1
35 /* Provide a CPP_SPEC appropriate for NetBSD/alpha. In addition to
36 the standard NetBSD specs, we also handle Alpha FP mode indications. */
38 #undef CPP_SPEC
39 #define CPP_SPEC \
40 "%{mieee:-D_IEEE_FP} \
41 %{mieee-with-inexact:-D_IEEE_FP -D_IEEE_FP_INEXACT} \
42 %(cpp_cpu) %(cpp_subtarget)"
44 #undef CPP_SUBTARGET_SPEC
45 #define CPP_SUBTARGET_SPEC \
46 "%{posix:-D_POSIX_SOURCE}"
49 /* Provide a LINK_SPEC appropriate for a NetBSD/alpha ELF target.
50 This is a copy of LINK_SPEC from <netbsd-elf.h> tweaked for
51 the alpha target. */
53 #undef LINK_SPEC
54 #define LINK_SPEC \
55 "%{G*} %{relax:-relax} \
56 %{O*:-O3} %{!O*:-O1} \
57 %{assert*} %{R*} \
58 %{shared:-shared} \
59 %{!shared: \
60 -dc -dp \
61 %{!nostdlib: \
62 %{!r*: \
63 %{!e*:-e __start}}} \
64 %{!static: \
65 %{rdynamic:-export-dynamic} \
66 %{!dynamic-linker:-dynamic-linker /usr/libexec/ld.elf_so}} \
67 %{static:-static}}"
70 /* Provide an ENDFILE_SPEC appropriate for NetBSD/alpha ELF. Here we
71 add crtend.o, which provides part of the support for getting
72 C++ file-scope static objects deconstructed after exiting "main".
74 We also need to handle the GCC option `-ffast-math'. */
76 #undef ENDFILE_SPEC
77 #define ENDFILE_SPEC \
78 "%{ffast-math|funsafe-math-optimizations:crtfm%O%s} \
79 %{!shared:crtend%O%s} %{shared:crtendS%O%s}"
82 /* Make gcc agree with <machine/ansi.h> */
84 #undef WCHAR_TYPE
85 #define WCHAR_TYPE "int"
87 #undef WCHAR_UNSIGNED
88 #define WCHAR_UNSIGNED 0
90 #undef WCHAR_TYPE_SIZE
91 #define WCHAR_TYPE_SIZE 32
93 #undef WINT_TYPE
94 #define WINT_TYPE "int"
96 #undef TARGET_VERSION
97 #define TARGET_VERSION fprintf (stderr, " (NetBSD/alpha ELF)");