]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/config/rs6000/netbsd.h
Update copyright years.
[thirdparty/gcc.git] / gcc / config / rs6000 / netbsd.h
CommitLineData
93006578 1/* Definitions of target machine for GNU compiler,
2 for PowerPC NetBSD systems.
f1717362 3 Copyright (C) 2002-2016 Free Software Foundation, Inc.
5eeaefac 4 Contributed by Wasabi Systems, Inc.
93006578 5
3a5a28e2 6 This file is part of GCC.
93006578 7
3a5a28e2 8 GCC is free software; you can redistribute it and/or modify it
9 under the terms of the GNU General Public License as published
038d1e19 10 by the Free Software Foundation; either version 3, or (at your
3a5a28e2 11 option) any later version.
93006578 12
3a5a28e2 13 GCC is distributed in the hope that it will be useful, but WITHOUT
14 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
15 or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
16 License for more details.
93006578 17
3a5a28e2 18 You should have received a copy of the GNU General Public License
038d1e19 19 along with GCC; see the file COPYING3. If not see
20 <http://www.gnu.org/licenses/>. */
93006578 21
3a5a28e2 22#undef TARGET_OS_CPP_BUILTINS /* FIXME: sysv4.h should not define this! */
5eeaefac 23#define TARGET_OS_CPP_BUILTINS() \
24 do \
25 { \
26 NETBSD_OS_CPP_BUILTINS_ELF(); \
27 builtin_define ("__powerpc__"); \
28 builtin_assert ("cpu=powerpc"); \
29 builtin_assert ("machine=powerpc"); \
30 } \
31 while (0)
93006578 32
a429a994 33/* Override the default from rs6000.h to avoid conflicts with macros
34 defined in NetBSD header files. */
35
3a5a28e2 36#undef RS6000_CPU_CPP_ENDIAN_BUILTINS
a429a994 37#define RS6000_CPU_CPP_ENDIAN_BUILTINS() \
38 do \
39 { \
40 if (BYTES_BIG_ENDIAN) \
41 { \
42 builtin_define ("__BIG_ENDIAN__"); \
43 builtin_assert ("machine=bigendian"); \
44 } \
45 else \
46 { \
47 builtin_define ("__LITTLE_ENDIAN__"); \
48 builtin_assert ("machine=littleendian"); \
49 } \
50 } \
51 while (0)
52
5eeaefac 53/* Make GCC agree with <machine/ansi.h>. */
93006578 54
3a5a28e2 55#undef SIZE_TYPE
5eeaefac 56#define SIZE_TYPE "unsigned int"
93006578 57
3a5a28e2 58#undef PTRDIFF_TYPE
5eeaefac 59#define PTRDIFF_TYPE "int"
93006578 60
5eeaefac 61/* Undo the spec mess from sysv4.h, and just define the specs
62 the way NetBSD systems actually expect. */
93006578 63
3a5a28e2 64#undef CPP_SPEC
5eeaefac 65#define CPP_SPEC NETBSD_CPP_SPEC
93006578 66
3a5a28e2 67#undef LINK_SPEC
5eeaefac 68#define LINK_SPEC \
69 "%{!msdata=none:%{G*}} %{msdata=none:-G0} \
70 %(netbsd_link_spec)"
93006578 71
5eeaefac 72#define NETBSD_ENTRY_POINT "_start"
93006578 73
3a5a28e2 74#undef STARTFILE_SPEC
5eeaefac 75#define STARTFILE_SPEC NETBSD_STARTFILE_SPEC
93006578 76
3a5a28e2 77#undef ENDFILE_SPEC
19872d0b 78#define ENDFILE_SPEC "%(netbsd_endfile_spec)"
93006578 79
3a5a28e2 80#undef LIB_SPEC
5eeaefac 81#define LIB_SPEC NETBSD_LIB_SPEC
82
3a5a28e2 83#undef SUBTARGET_EXTRA_SPECS
5eeaefac 84#define SUBTARGET_EXTRA_SPECS \
85 { "netbsd_link_spec", NETBSD_LINK_SPEC_ELF }, \
86 { "netbsd_entry_point", NETBSD_ENTRY_POINT }, \
87 { "netbsd_endfile_spec", NETBSD_ENDFILE_SPEC },
5b53fefa 88
5eeaefac 89
fc222f44 90/* Use standard DWARF numbering for DWARF debugging information. */
91#define RS6000_USE_DWARF_NUMBERING
92