OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [tags/] [gnu-src/] [gcc-4.5.1/] [gcc-4.5.1-or32-1.0rc2/] [gcc/] [config/] [m32r/] [linux.h] - Blame information for rev 435

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 282 jeremybenn
/* Definitions for Renesas M32R running Linux-based GNU systems using ELF.
2
   Copyright (C) 2003, 2004, 2006, 2007 Free Software Foundation, Inc.
3
 
4
   This file is part of GCC.
5
 
6
   GCC is free software; you can redistribute it and/or modify it
7
   under the terms of the GNU General Public License as published
8
   by the Free Software Foundation; either version 3, or (at your
9
   option) any later version.
10
 
11
   GCC is distributed in the hope that it will be useful, but WITHOUT
12
   ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
13
   or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public
14
   License for more details.
15
 
16
   You should have received a copy of the GNU General Public License
17
   along with GCC; see the file COPYING3.  If not see
18
   <http://www.gnu.org/licenses/>.  */
19
 
20
#define LINUX_DEFAULT_ELF
21
 
22
/* A lie, I guess, but the general idea behind linux/ELF is that we are
23
   supposed to be outputting something that will assemble under SVr4.
24
   This gets us pretty close.  */
25
 
26
#define HANDLE_SYSV_PRAGMA
27
 
28
#undef  HANDLE_PRAGMA_PACK
29
 
30
#undef  TARGET_VERSION
31
#define TARGET_VERSION fprintf (stderr, " (M32R GNU/Linux with ELF)");
32
 
33
#undef  SIZE_TYPE
34
#define SIZE_TYPE "unsigned int"
35
 
36
#undef  PTRDIFF_TYPE
37
#define PTRDIFF_TYPE "int"
38
 
39
#undef  WCHAR_TYPE
40
#define WCHAR_TYPE "long int"
41
 
42
#undef  WCHAR_TYPE_SIZE
43
#define WCHAR_TYPE_SIZE BITS_PER_WORD
44
 
45
/* Provide a LINK_SPEC appropriate for Linux.  Here we provide support
46
   for the special GCC options -static and -shared, which allow us to
47
   link things in one of these three modes by applying the appropriate
48
   combinations of options at link-time. We like to support here for
49
   as many of the other GNU linker options as possible. But I don't
50
   have the time to search for those flags. I am sure how to add
51
   support for -soname shared_object_name. H.J.
52
 
53
   I took out %{v:%{!V:-V}}. It is too much :-(. They can use
54
   -Wl,-V.
55
 
56
   When the -shared link option is used a final link is not being
57
   done.  */
58
 
59
/* If ELF is the default format, we should not use /lib/elf.  */
60
 
61
#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
62
 
63
#undef  LINK_SPEC
64
#if TARGET_LITTLE_ENDIAN
65
#define LINK_SPEC "%(link_cpu) -m m32rlelf_linux %{shared:-shared} \
66
  %{!shared: \
67
    %{!ibcs: \
68
      %{!static: \
69
        %{rdynamic:-export-dynamic} \
70
        %{!dynamic-linker:-dynamic-linker " LINUX_DYNAMIC_LINKER "}} \
71
        %{static:-static}}}"
72
#else
73
#define LINK_SPEC "%(link_cpu) -m m32relf_linux %{shared:-shared} \
74
  %{!shared: \
75
    %{!ibcs: \
76
      %{!static: \
77
        %{rdynamic:-export-dynamic} \
78
        %{!dynamic-linker:-dynamic-linker " LINUX_DYNAMIC_LINKER "}} \
79
        %{static:-static}}}"
80
#endif
81
 
82
#undef  LIB_SPEC
83
#define LIB_SPEC \
84
  "%{pthread:-lpthread} \
85
   %{shared: -lc} \
86
   %{!shared: \
87
       %{mieee-fp:-lieee} \
88
       %{profile:-lc_p} %{!profile: -lc}}"
89
 
90
#undef  STARTFILE_SPEC
91
#if defined HAVE_LD_PIE
92
#define STARTFILE_SPEC \
93
  "%{!shared: %{pg|p|profile:gcrt1.o%s;pie:Scrt1.o%s;:crt1.o%s}} \
94
   crti.o%s %{static:crtbeginT.o%s;shared|pie:crtbeginS.o%s;:crtbegin.o%s}"
95
#else
96
#define STARTFILE_SPEC \
97
  "%{!shared: \
98
     %{pg:gcrt1.o%s} %{!pg:%{p:gcrt1.o%s} %{!p:crt1.o%s}}}\
99
   crti.o%s %{!shared:crtbegin.o%s} %{shared:crtbeginS.o%s}"
100
#endif
101
 
102
#undef  ENDFILE_SPEC
103
#define ENDFILE_SPEC \
104
  "%{shared|pie:crtendS.o%s;:crtend.o%s} crtn.o%s"
105
 
106
#undef  SUBTARGET_CPP_SPEC
107
#define SUBTARGET_CPP_SPEC "\
108
   %{posix:-D_POSIX_SOURCE} \
109
   %{pthread:-D_REENTRANT -D_PTHREADS} \
110
"
111
 
112
#define TARGET_OS_CPP_BUILTINS() LINUX_TARGET_OS_CPP_BUILTINS()
113
 
114
#define TARGET_ASM_FILE_END file_end_indicate_exec_stack

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.