~ubuntu-branches/debian/sid/gcc-4.8/sid

« back to all changes in this revision

Viewing changes to .svn/pristine/d0/d0f4c28abe60d6c4bd16703f67668a5f52f9c327.svn-base

  • Committer: Package Import Robot
  • Author(s): Matthias Klose
  • Date: 2014-12-19 19:48:34 UTC
  • Revision ID: package-import@ubuntu.com-20141219194834-4dz1q7rrn5pad823
Tags: 4.8.4-1
* GCC 4.8.4 release.
  - Fix PR target/61407 (darwin), PR middle-end/58624 (ice),
    PR sanitizer/64265 (wrong code).
* Require recent binutils to pass go test failures.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# DP: On linux targets pass --as-needed by default to the linker.
 
2
 
 
3
Index: b/src/gcc/config/aarch64/aarch64-linux.h
 
4
===================================================================
 
5
--- a/src/gcc/config/aarch64/aarch64-linux.h
 
6
+++ b/src/gcc/config/aarch64/aarch64-linux.h
 
7
@@ -25,6 +25,7 @@
 
8
 
 
9
 #define LINUX_TARGET_LINK_SPEC  "%{h*}         \
 
10
    --hash-style=gnu                            \
 
11
+   --as-needed                                 \
 
12
    %{static:-Bstatic}                          \
 
13
    %{shared:-shared}                           \
 
14
    %{symbolic:-Bsymbolic}                      \
 
15
Index: b/src/gcc/config/ia64/linux.h
 
16
===================================================================
 
17
--- a/src/gcc/config/ia64/linux.h
 
18
+++ b/src/gcc/config/ia64/linux.h
 
19
@@ -58,7 +58,7 @@
 
20
 #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux-ia64.so.2"
 
21
 
 
22
 #undef LINK_SPEC
 
23
-#define LINK_SPEC " --hash-style=gnu \
 
24
+#define LINK_SPEC " --hash-style=gnu --as-needed \
 
25
   %{shared:-shared} \
 
26
   %{!shared: \
 
27
     %{!static: \
 
28
Index: b/src/gcc/config/sparc/linux.h
 
29
===================================================================
 
30
--- a/src/gcc/config/sparc/linux.h
 
31
+++ b/src/gcc/config/sparc/linux.h
 
32
@@ -86,7 +86,7 @@
 
33
 #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
 
34
 
 
35
 #undef  LINK_SPEC
 
36
-#define LINK_SPEC "-m elf32_sparc --hash-style=gnu %{shared:-shared} \
 
37
+#define LINK_SPEC "-m elf32_sparc --hash-style=gnu --as-needed %{shared:-shared} \
 
38
   %{!mno-relax:%{!r:-relax}} \
 
39
   %{!shared: \
 
40
     %{!static: \
 
41
Index: b/src/gcc/config/s390/linux.h
 
42
===================================================================
 
43
--- a/src/gcc/config/s390/linux.h
 
44
+++ b/src/gcc/config/s390/linux.h
 
45
@@ -65,7 +65,7 @@
 
46
 
 
47
 #undef  LINK_SPEC
 
48
 #define LINK_SPEC \
 
49
-  "%{m31:-m elf_s390}%{m64:-m elf64_s390} --hash-style=gnu \
 
50
+  "%{m31:-m elf_s390}%{m64:-m elf64_s390} --hash-style=gnu --as-needed \
 
51
    %{shared:-shared} \
 
52
    %{!shared: \
 
53
       %{static:-static} \
 
54
Index: b/src/gcc/config/rs6000/linux64.h
 
55
===================================================================
 
56
--- a/src/gcc/config/rs6000/linux64.h
 
57
+++ b/src/gcc/config/rs6000/linux64.h
 
58
@@ -385,11 +385,11 @@
 
59
                                           " -m elf64ppc")
 
60
 #endif
 
61
 
 
62
-#define LINK_OS_LINUX_SPEC32 LINK_OS_LINUX_EMUL32 " --hash-style=gnu %{!shared: %{!static: \
 
63
+#define LINK_OS_LINUX_SPEC32 LINK_OS_LINUX_EMUL32 " --hash-style=gnu --as-needed %{!shared: %{!static: \
 
64
   %{rdynamic:-export-dynamic} \
 
65
   -dynamic-linker " GNU_USER_DYNAMIC_LINKER32 "}}"
 
66
 
 
67
-#define LINK_OS_LINUX_SPEC64 LINK_OS_LINUX_EMUL64 " --hash-style=gnu %{!shared: %{!static: \
 
68
+#define LINK_OS_LINUX_SPEC64 LINK_OS_LINUX_EMUL64 " --hash-style=gnu --as-needed %{!shared: %{!static: \
 
69
   %{rdynamic:-export-dynamic} \
 
70
   -dynamic-linker " GNU_USER_DYNAMIC_LINKER64 "}}"
 
71
 
 
72
Index: b/src/gcc/config/rs6000/sysv4.h
 
73
===================================================================
 
74
--- a/src/gcc/config/rs6000/sysv4.h
 
75
+++ b/src/gcc/config/rs6000/sysv4.h
 
76
@@ -799,7 +799,7 @@
 
77
 #define GNU_USER_DYNAMIC_LINKER \
 
78
   CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER, UCLIBC_DYNAMIC_LINKER)
 
79
 
 
80
-#define LINK_OS_LINUX_SPEC "-m elf32ppclinux --hash-style=gnu %{!shared: %{!static: \
 
81
+#define LINK_OS_LINUX_SPEC "-m elf32ppclinux --hash-style=gnu --as-needed %{!shared: %{!static: \
 
82
   %{rdynamic:-export-dynamic} \
 
83
   -dynamic-linker " GNU_USER_DYNAMIC_LINKER "}}"
 
84
 
 
85
Index: b/src/gcc/config/i386/gnu-user64.h
 
86
===================================================================
 
87
--- a/src/gcc/config/i386/gnu-user64.h
 
88
+++ b/src/gcc/config/i386/gnu-user64.h
 
89
@@ -57,6 +57,7 @@
 
90
                    %{" SPEC_32 ":-m " GNU_USER_LINK_EMULATION32 "} \
 
91
                    %{" SPEC_X32 ":-m " GNU_USER_LINK_EMULATIONX32 "} \
 
92
   --hash-style=gnu \
 
93
+  --as-needed \
 
94
   %{shared:-shared} \
 
95
   %{!shared: \
 
96
     %{!static: \
 
97
Index: b/src/gcc/config/i386/gnu-user.h
 
98
===================================================================
 
99
--- a/src/gcc/config/i386/gnu-user.h
 
100
+++ b/src/gcc/config/i386/gnu-user.h
 
101
@@ -74,7 +74,7 @@
 
102
   { "link_emulation", GNU_USER_LINK_EMULATION },\
 
103
   { "dynamic_linker", GNU_USER_DYNAMIC_LINKER }
 
104
 
 
105
-#define GNU_USER_TARGET_LINK_SPEC "-m %(link_emulation) --hash-style=gnu %{shared:-shared} \
 
106
+#define GNU_USER_TARGET_LINK_SPEC "-m %(link_emulation) --hash-style=gnu --as-needed %{shared:-shared} \
 
107
   %{!shared: \
 
108
     %{!static: \
 
109
       %{rdynamic:-export-dynamic} \
 
110
Index: b/src/gcc/config/alpha/linux-elf.h
 
111
===================================================================
 
112
--- a/src/gcc/config/alpha/linux-elf.h
 
113
+++ b/src/gcc/config/alpha/linux-elf.h
 
114
@@ -37,7 +37,7 @@
 
115
 
 
116
 #define ELF_DYNAMIC_LINKER     GNU_USER_DYNAMIC_LINKER
 
117
 
 
118
-#define LINK_SPEC "-m elf64alpha --hash-style=gnu %{G*} %{relax:-relax}        \
 
119
+#define LINK_SPEC "-m elf64alpha --hash-style=gnu --as-needed %{G*} %{relax:-relax}    \
 
120
   %{O*:-O3} %{!O*:-O1}                                         \
 
121
   %{shared:-shared}                                            \
 
122
   %{!shared:                                                   \
 
123
Index: b/src/gcc/config/arm/linux-elf.h
 
124
===================================================================
 
125
--- a/src/gcc/config/arm/linux-elf.h
 
126
+++ b/src/gcc/config/arm/linux-elf.h
 
127
@@ -68,6 +68,7 @@
 
128
      -dynamic-linker " GNU_USER_DYNAMIC_LINKER "} \
 
129
    -X \
 
130
    --hash-style=gnu \
 
131
+   --as-needed \
 
132
    %{mbig-endian:-EB} %{mlittle-endian:-EL}" \
 
133
    SUBTARGET_EXTRA_LINK_SPEC
 
134