6 information" ELF header type "SUNW_syminfo" and Solaris 10 "DTrace |
6 information" ELF header type "SUNW_syminfo" and Solaris 10 "DTrace |
7 Object Format" ELF header type. Also, fix the path to the dynamic |
7 Object Format" ELF header type. Also, fix the path to the dynamic |
8 linker under Solaris 10/amd64. |
8 linker under Solaris 10/amd64. |
9 |
9 |
10 Index: include/elf/common.h |
10 Index: include/elf/common.h |
11 --- include/elf/common.h.orig 2007-08-28 19:19:40 +0200 |
11 --- include/elf/common.h.orig 2010-05-18 05:31:06.000000000 +0200 |
12 +++ include/elf/common.h 2007-08-29 09:30:04 +0200 |
12 +++ include/elf/common.h 2010-12-09 16:48:56.000000000 +0100 |
13 @@ -353,6 +353,9 @@ |
13 @@ -474,6 +474,9 @@ |
14 #define SHT_SUNW_verdef 0x6ffffffd /* Versions defined by file */ |
14 #define SHT_SUNW_verdef 0x6ffffffd /* Versions defined by file */ |
15 #define SHT_SUNW_verneed 0x6ffffffe /* Versions needed by file */ |
15 #define SHT_SUNW_verneed 0x6ffffffe /* Versions needed by file */ |
16 #define SHT_SUNW_versym 0x6fffffff /* Symbol versions */ |
16 #define SHT_SUNW_versym 0x6fffffff /* Symbol versions */ |
17 +#define SHT_SUNW_syminfo 0x6ffffffc /* Symbol information */ |
17 +#define SHT_SUNW_syminfo 0x6ffffffc /* Symbol information */ |
18 +#define SHT_SUNW_signature 0x6ffffff6 /* Solaris Cryptographic Framework: Digital Signature */ |
18 +#define SHT_SUNW_signature 0x6ffffff6 /* Solaris Cryptographic Framework: Digital Signature */ |
19 +#define SHT_SUNW_dof 0x6ffffff4 /* Solaris DTrace Object Format */ |
19 +#define SHT_SUNW_dof 0x6ffffff4 /* Solaris DTrace Object Format */ |
20 |
20 |
21 #define SHT_GNU_verdef SHT_SUNW_verdef |
21 #define SHT_GNU_verdef SHT_SUNW_verdef |
22 #define SHT_GNU_verneed SHT_SUNW_verneed |
22 #define SHT_GNU_verneed SHT_SUNW_verneed |
23 Index: bfd/elf.c |
23 Index: bfd/elf.c |
24 --- bfd/elf.c.orig 2007-08-28 19:19:33 +0200 |
24 --- bfd/elf.c.orig 2010-10-29 14:10:24.000000000 +0200 |
25 +++ bfd/elf.c 2007-08-29 09:30:04 +0200 |
25 +++ bfd/elf.c 2010-12-09 16:48:57.000000000 +0100 |
26 @@ -1793,6 +1793,11 @@ |
26 @@ -1884,6 +1884,11 @@ |
27 elf_tdata (abfd)->dynverref_hdr = *hdr; |
27 elf_tdata (abfd)->dynverref_hdr = *hdr; |
28 return _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex); |
28 return _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex); |
29 |
29 |
30 + case SHT_SUNW_syminfo: |
30 + case SHT_SUNW_syminfo: |
31 + /* case SHT_SUNW_signature: conflicts with new SHT_GNU_HASH in Binutils 2.18 */ |
31 + /* case SHT_SUNW_signature: conflicts with new SHT_GNU_HASH in Binutils 2.18 */ |
47 + |
47 + |
48 switch (bfd_get_arch (abfd)) |
48 switch (bfd_get_arch (abfd)) |
49 { |
49 { |
50 case bfd_arch_unknown: |
50 case bfd_arch_unknown: |
51 Index: bfd/elf64-x86-64.c |
51 Index: bfd/elf64-x86-64.c |
52 --- bfd/elf64-x86-64.c.orig 2007-08-06 21:59:33 +0200 |
52 --- bfd/elf64-x86-64.c.orig 2010-10-21 14:29:02.000000000 +0200 |
53 +++ bfd/elf64-x86-64.c 2007-08-29 09:30:04 +0200 |
53 +++ bfd/elf64-x86-64.c 2010-12-09 16:48:57.000000000 +0100 |
54 @@ -345,7 +345,11 @@ |
54 @@ -360,7 +360,11 @@ |
55 /* The name of the dynamic interpreter. This is put in the .interp |
55 /* The name of the dynamic interpreter. This is put in the .interp |
56 section. */ |
56 section. */ |
57 |
57 |
58 +#if defined(OPENPKG_OS_SOLARIS) |
58 +#if defined(OPENPKG_OS_SOLARIS) |
59 +#define ELF_DYNAMIC_INTERPRETER "/lib/amd64/ld.so.1" |
59 +#define ELF_DYNAMIC_INTERPRETER "/lib/amd64/ld.so.1" |
67 ----------------------------------------------------------------------------- |
67 ----------------------------------------------------------------------------- |
68 |
68 |
69 Support FreeBSD >= 4.10 by fixing platform detection. |
69 Support FreeBSD >= 4.10 by fixing platform detection. |
70 |
70 |
71 Index: bfd/configure |
71 Index: bfd/configure |
72 --- bfd/configure.orig 2007-08-28 22:19:51 +0200 |
72 --- bfd/configure.orig 2010-12-08 09:37:34.000000000 +0100 |
73 +++ bfd/configure 2007-08-29 09:30:04 +0200 |
73 +++ bfd/configure 2010-12-09 16:48:57.000000000 +0100 |
74 @@ -17459,6 +17459,10 @@ |
74 @@ -13876,6 +13876,10 @@ |
75 i[3-7]86-*-bsdi) |
75 i[3-7]86-*-bsdi) |
76 COREFILE= |
76 COREFILE= |
77 ;; |
77 ;; |
78 + i[3456]86-*-freebsd4.1[0-9]*) |
78 + i[3456]86-*-freebsd4.1[0-9]*) |
79 + COREFILE='' |
79 + COREFILE='' |
86 ----------------------------------------------------------------------------- |
86 ----------------------------------------------------------------------------- |
87 |
87 |
88 Fight problems with --disable-nls under Solaris |
88 Fight problems with --disable-nls under Solaris |
89 |
89 |
90 Index: gas/asintl.h |
90 Index: gas/asintl.h |
91 --- gas/asintl.h.orig 2007-08-06 21:59:49 +0200 |
91 --- gas/asintl.h.orig 2007-07-03 13:01:02.000000000 +0200 |
92 +++ gas/asintl.h 2007-08-29 09:30:04 +0200 |
92 +++ gas/asintl.h 2010-12-09 16:48:57.000000000 +0100 |
93 @@ -20,6 +20,11 @@ |
93 @@ -20,6 +20,11 @@ |
94 Software Foundation, 51 Franklin Street - Fifth Floor, Boston, MA |
94 Software Foundation, 51 Franklin Street - Fifth Floor, Boston, MA |
95 02110-1301, USA. */ |
95 02110-1301, USA. */ |
96 |
96 |
97 +#ifndef ENABLE_NLS |
97 +#ifndef ENABLE_NLS |
116 + |
116 + |
117 #ifdef HAVE_LOCALE_H |
117 #ifdef HAVE_LOCALE_H |
118 #endif |
118 #endif |
119 #ifndef SEEK_CUR |
119 #ifndef SEEK_CUR |
120 Index: ld/Makefile.in |
120 Index: ld/Makefile.in |
121 --- ld/Makefile.in.orig 2007-08-06 22:29:54 +0200 |
121 --- ld/Makefile.in.orig 2010-11-05 11:34:22.000000000 +0100 |
122 +++ ld/Makefile.in 2007-08-29 09:30:04 +0200 |
122 +++ ld/Makefile.in 2010-12-09 16:48:57.000000000 +0100 |
123 @@ -287,7 +287,7 @@ |
123 @@ -360,7 +360,7 @@ |
124 # We put the scripts in the directory $(scriptdir)/ldscripts. |
124 # We put the scripts in the directory $(scriptdir)/ldscripts. |
125 # We can't put the scripts in $(datadir) because the SEARCH_DIR |
125 # We can't put the scripts in $(datadir) because the SEARCH_DIR |
126 # directives need to be different for native and cross linkers. |
126 # directives need to be different for native and cross linkers. |
127 -scriptdir = $(tooldir)/lib |
127 -scriptdir = $(tooldir)/lib |
128 +scriptdir = $(libdir) |
128 +scriptdir = $(libdir) |
130 BFDDIR = $(BASEDIR)/bfd |
130 BFDDIR = $(BASEDIR)/bfd |
131 INCDIR = $(BASEDIR)/include |
131 INCDIR = $(BASEDIR)/include |
132 |
132 |
133 ----------------------------------------------------------------------------- |
133 ----------------------------------------------------------------------------- |
134 |
134 |
135 workaround problems under Mac OS X. |
135 Workaround problems under Mac OS X. |
136 |
136 |
137 Index: libiberty/fibheap.c |
137 Index: libiberty/fibheap.c |
138 --- libiberty/fibheap.c.orig 2005-05-10 17:33:33 +0200 |
138 --- libiberty/fibheap.c.orig 2009-05-29 05:01:15.000000000 +0200 |
139 +++ libiberty/fibheap.c 2007-08-29 09:30:04 +0200 |
139 +++ libiberty/fibheap.c 2010-12-09 16:48:57.000000000 +0100 |
140 @@ -34,8 +34,11 @@ |
140 @@ -34,8 +34,11 @@ |
141 #include "libiberty.h" |
141 #include "libiberty.h" |
142 #include "fibheap.h" |
142 #include "fibheap.h" |
143 |
143 |
144 - |
144 - |
159 like the issue itself exists since a longer time, but in recent GNU |
159 like the issue itself exists since a longer time, but in recent GNU |
160 binutils this additional message was introduced. As we cannot observe |
160 binutils this additional message was introduced. As we cannot observe |
161 any problems and this message really confused, just disable it for now. |
161 any problems and this message really confused, just disable it for now. |
162 |
162 |
163 Index: bfd/elf-eh-frame.c |
163 Index: bfd/elf-eh-frame.c |
164 --- bfd/elf-eh-frame.c.orig 2007-08-06 21:59:22 +0200 |
164 --- bfd/elf-eh-frame.c.orig 2010-04-09 16:40:15.000000000 +0200 |
165 +++ bfd/elf-eh-frame.c 2007-11-11 15:46:44 +0100 |
165 +++ bfd/elf-eh-frame.c 2010-12-09 16:48:57.000000000 +0100 |
166 @@ -970,9 +970,11 @@ |
166 @@ -909,9 +909,11 @@ |
167 return offset != sec->rawsize; |
167 goto success; |
168 |
168 |
169 free_no_table: |
169 free_no_table: |
170 +#if 0 |
170 +#if 0 |
171 (*info->callbacks->einfo) |
171 (*info->callbacks->einfo) |
172 (_("%P: error in %B(%A); no .eh_frame_hdr table will be created.\n"), |
172 (_("%P: error in %B(%A); no .eh_frame_hdr table will be created.\n"), |
173 abfd, sec); |
173 abfd, sec); |
174 +#endif |
174 +#endif |
175 if (ehbuf) |
175 hdr_info->table = FALSE; |
176 free (ehbuf); |
|
177 if (sec_info) |
176 if (sec_info) |
178 Index: bfd/elflink.c |
177 free (sec_info); |
179 diff -Nau bfd/elflink.c.orig bfd/elflink.c |
178 |
180 --- bfd/elflink.c.orig 2007-08-24 16:01:08.000000000 +0200 |
|
181 +++ bfd/elflink.c 2009-01-11 14:07:54.705525343 +0100 |
|
182 @@ -4231,7 +4231,15 @@ |
|
183 h->ref_regular_nonweak = 1; |
|
184 } |
|
185 else |
|
186 - h->def_regular = 1; |
|
187 + { |
|
188 + h->def_regular = 1; |
|
189 + if (h->def_dynamic) |
|
190 + { |
|
191 + h->def_dynamic = 0; |
|
192 + h->ref_dynamic = 1; |
|
193 + h->dynamic_def = 1; |
|
194 + } |
|
195 + } |
|
196 if (! info->executable |
|
197 || h->def_dynamic |
|
198 || h->ref_dynamic) |
|