]> git.pld-linux.org Git - packages/elfutils.git/blame - elfutils-gcc34.patch
- stage 5, NFY (6 of 31 tests failed).
[packages/elfutils.git] / elfutils-gcc34.patch
CommitLineData
ea01f8ef
PS
1diff -uNr elfutils-0.94.orig/libdw/dwarf_getloclist.c elfutils-0.94/libdw/dwarf_getloclist.c
2--- elfutils-0.94.orig/libdw/dwarf_getloclist.c 2004-01-09 09:39:54.000000000 +0100
3+++ elfutils-0.94/libdw/dwarf_getloclist.c 2004-04-02 14:14:37.667598440 +0200
4@@ -177,7 +177,7 @@
5 if (unlikely (data >= end_data))
6 goto invalid;
7
8- newloc->number = *((int8_t *) data)++;
9+ newloc->number = *(int8_t *)data++;
10 break;
11
12 case DW_OP_const2u:
13diff -uNr elfutils-0.94.orig/libdw/dwarf_getsrclines.c elfutils-0.94/libdw/dwarf_getsrclines.c
14--- elfutils-0.94.orig/libdw/dwarf_getsrclines.c 2004-01-12 01:30:17.000000000 +0100
15+++ elfutils-0.94/libdw/dwarf_getsrclines.c 2004-04-02 14:14:35.850874624 +0200
16@@ -149,7 +149,7 @@
17 uint_fast8_t default_is_stmt = *linep++;
18
19 /* Now the line base. */
20- int_fast8_t line_base = *((int_fast8_t *) linep)++;
21+ int_fast8_t line_base = *(int_fast8_t *)linep++;
22
23 /* And the line range. */
24 uint_fast8_t line_range = *linep++;
25diff -uNr elfutils-0.94.orig/libdw/memory-access.h elfutils-0.94/libdw/memory-access.h
26--- elfutils-0.94.orig/libdw/memory-access.h 2004-01-16 18:43:30.000000000 +0100
27+++ elfutils-0.94/libdw/memory-access.h 2004-04-02 14:17:02.641559048 +0200
28@@ -23,19 +23,19 @@
29 /* Number decoding macros. See 7.6 Variable Length Data. */
30 #define get_uleb128(var, addr) \
31 do { \
32- unsigned char __b = *((const unsigned char *) addr)++; \
33+ unsigned char __b = *(const unsigned char *)addr++; \
34 var = __b & 0x7f; \
35 if (__b & 0x80) \
36 { \
37- __b = *((const unsigned char *) addr)++; \
38+ __b = *(const unsigned char *)addr++; \
39 var |= (__b & 0x7f) << 7; \
40 if (__b & 0x80) \
41 { \
42- __b = *((const unsigned char *) addr)++; \
43+ __b = *(const unsigned char *)addr++; \
44 var |= (__b & 0x7f) << 14; \
45 if (__b & 0x80) \
46 { \
47- __b = *((const unsigned char *) addr)++; \
48+ __b = *(const unsigned char *)addr++; \
49 var |= (__b & 0x7f) << 21; \
50 if (__b & 0x80) \
51 /* Other implementation set VALUE to UINT_MAX in this \
52@@ -49,7 +49,7 @@
53 /* The signed case is a big more complicated. */
54 #define get_sleb128(var, addr) \
55 do { \
56- unsigned char __b = *((const unsigned char *) addr)++; \
57+ unsigned char __b = *(const unsigned char *)addr++; \
58 int32_t __res = __b & 0x7f; \
59 if ((__b & 0x80) == 0) \
60 { \
61@@ -58,7 +58,7 @@
62 } \
63 else \
64 { \
65- __b = *((const unsigned char *) addr)++; \
66+ __b = *(const unsigned char *)addr++; \
67 __res |= (__b & 0x7f) << 7; \
68 if ((__b & 0x80) == 0) \
69 { \
70@@ -67,7 +67,7 @@
71 } \
72 else \
73 { \
74- __b = *((const unsigned char *) addr)++; \
75+ __b = *(const unsigned char *)addr++; \
76 __res |= (__b & 0x7f) << 14; \
77 if ((__b & 0x80) == 0) \
78 { \
79@@ -76,7 +76,7 @@
80 } \
81 else \
82 { \
83- __b = *((const unsigned char *) addr)++; \
84+ __b = *(const unsigned char *)addr++; \
85 __res |= (__b & 0x7f) << 21; \
86 if ((__b & 0x80) == 0) \
87 { \
88@@ -202,29 +202,29 @@
89
90 #define read_2ubyte_unaligned_inc(Dbg, Addr) \
91 ({ uint16_t t_ = read_2ubyte_unaligned (Dbg, Addr); \
92- ++((const uint16_t *) (Addr)); \
93+ (Addr) += sizeof(uint16_t *); \
94 t_; })
95 #define read_2sbyte_unaligned_inc(Dbg, Addr) \
96 ({ int16_t t_ = read_2sbyte_unaligned (Dbg, Addr); \
97- ++((const int16_t *) (Addr)); \
98+ (Addr) += sizeof(int16_t *); \
99 t_; })
100
101 #define read_4ubyte_unaligned_inc(Dbg, Addr) \
102 ({ uint32_t t_ = read_4ubyte_unaligned (Dbg, Addr); \
103- ++((const uint32_t *) (Addr)); \
104+ (Addr) += sizeof(uint32_t *); \
105 t_; })
106 #define read_4sbyte_unaligned_inc(Dbg, Addr) \
107 ({ int32_t t_ = read_4sbyte_unaligned (Dbg, Addr); \
108- ++((const int32_t *) (Addr)); \
109+ (Addr) += sizeof(int32_t *); \
110 t_; })
111
112 #define read_8ubyte_unaligned_inc(Dbg, Addr) \
113 ({ uint64_t t_ = read_8ubyte_unaligned (Dbg, Addr); \
114- ++((const uint64_t *) (Addr)); \
115+ (Addr) += sizeof(uint64_t *); \
116 t_; })
117 #define read_8sbyte_unaligned_inc(Dbg, Addr) \
118 ({ int64_t t_ = read_8sbyte_unaligned (Dbg, Addr); \
119- ++((const int64_t *) (Addr)); \
120+ (Addr) += sizeof(int64_t *); \
121 t_; })
122
123 #endif /* memory-access.h */
124diff -uNr elfutils-0.94.orig/libelf/dl-hash.h elfutils-0.94/libelf/dl-hash.h
125--- elfutils-0.94.orig/libelf/dl-hash.h 2003-12-25 19:31:59.000000000 +0100
126+++ elfutils-0.94/libelf/dl-hash.h 2004-04-02 14:15:11.725420864 +0200
548615b1
PS
127@@ -26,28 +26,28 @@
128 __attribute__ ((__pure__))
129 _dl_elf_hash (const char *name)
130 {
131- unsigned int hash = (unsigned int) *((const unsigned char *) name)++;
132+ unsigned int hash = (unsigned int) *(const unsigned char *)name++;
133 if (*name != '\0')
134 {
135 hash = ((hash << 4)
136- + (unsigned int) *((const unsigned char *) name)++);
137+ + (unsigned int) *(const unsigned char *)name++);
138 if (*name != '\0')
139 {
140 hash = ((hash << 4)
141- + (unsigned int) *((const unsigned char *) name)++);
142+ + (unsigned int) *(const unsigned char *)name++);
143 if (*name != '\0')
144 {
145 hash = ((hash << 4)
146- + (unsigned int) *((const unsigned char *) name)++);
147+ + (unsigned int) *(const unsigned char *)name++);
148 if (*name != '\0')
149 {
150 hash = ((hash << 4)
151- + (unsigned int) *((const unsigned char *) name)++);
152+ + (unsigned int) *(const unsigned char *)name++);
153 while (*name != '\0')
154 {
155 unsigned int hi;
156 hash = ((hash << 4)
157- + (unsigned int) *((const unsigned char *) name)++);
158+ + (unsigned int) *(const unsigned char *)name++);
159 hi = hash & 0xf0000000;
160
161 /* The algorithm specified in the ELF ABI is as
ea01f8ef
PS
162diff -uNr elfutils-0.94.orig/libelf/gelf_xlate.c elfutils-0.94/libelf/gelf_xlate.c
163--- elfutils-0.94.orig/libelf/gelf_xlate.c 2003-12-25 19:42:38.000000000 +0100
164+++ elfutils-0.94/libelf/gelf_xlate.c 2004-04-02 14:16:48.045777944 +0200
165@@ -73,9 +73,10 @@
d4ec83b9 166 if (dest < ptr) \
ea01f8ef 167 while (n-- > 0) \
9a4fa4d8 168 { \
d4ec83b9 169- *((word##Bytes##_t *) dest)++ = \
ea01f8ef
PS
170+ *((word##Bytes##_t *)dest) = \
171 LEN##Bytes##_SWAP ((word##Bytes##_t *) ptr); \
d4ec83b9 172- ((word##Bytes##_t *) ptr)++; \
ea01f8ef
PS
173+ dest += sizeof(word##Bytes##_t *); \
174+ ptr += sizeof(word##Bytes##_t *); \
9a4fa4d8 175 } \
d4ec83b9
PS
176 else \
177 { \
ea01f8ef
PS
178diff -uNr elfutils-0.94.orig/src/ldgeneric.c elfutils-0.94/src/ldgeneric.c
179--- elfutils-0.94.orig/src/ldgeneric.c 2003-08-18 01:49:51.000000000 +0200
180+++ elfutils-0.94/src/ldgeneric.c 2004-04-02 14:15:18.573379816 +0200
181@@ -2449,9 +2449,8 @@
182 ld_state.outfname = "a.out";
183
184 size_t outfname_len = strlen (ld_state.outfname);
185- char *tempfname = (char *) ld_state.tempfname
186- = (char *) obstack_alloc (&ld_state.smem,
187- outfname_len + sizeof (".XXXXXX"));
188+ char *tempfname = ld_state.tempfname
189+ = obstack_alloc (&ld_state.smem, outfname_len + sizeof (".XXXXXX"));
190
191 int fd;
192 int try = 0;
193diff -uNr elfutils-0.94.orig/src/ld.h elfutils-0.94/src/ld.h
194--- elfutils-0.94.orig/src/ld.h 2003-08-12 08:46:39.000000000 +0200
195+++ elfutils-0.94/src/ld.h 2004-04-02 14:15:18.562381488 +0200
196@@ -752,7 +752,7 @@
197 /* Name of the output file. */
198 const char *outfname;
199 /* Name of the temporary file we initially create. */
200- const char *tempfname;
201+ char *tempfname;
202 /* File descriptor opened for the output file. */
203 int outfd;
204 /* The ELF descriptor for the output file. */
205diff -uNr elfutils-0.94.orig/src/readelf.c elfutils-0.94/src/readelf.c
206--- elfutils-0.94.orig/src/readelf.c 2004-01-16 10:29:37.000000000 +0100
207+++ elfutils-0.94/src/readelf.c 2004-04-02 14:16:44.674290488 +0200
208@@ -2974,7 +2974,7 @@
209 Dwarf_Word offset = 0;
210 while (len-- > 0)
211 {
212- size_t op = *((unsigned char *) data)++;
213+ size_t op = *(unsigned char *)data++;
214
215 switch (op)
216 {
217@@ -3004,7 +3004,7 @@
218 case DW_OP_const1u:
219 printf (" %*s [%4" PRIuMAX "] %s %" PRIu8 "\n",
220 (int) (20 + level * 2), "", (uintmax_t) offset,
221- known[op] ?: "???", *((uint8_t *) data)++);
222+ known[op] ?: "???", *(uint8_t *)data++);
223 --len;
224 offset += 2;
225 break;
226@@ -3039,7 +3039,7 @@
227 case DW_OP_const1s:
228 printf (" %*s [%4" PRIuMAX "] %s %" PRId8 "\n",
229 (int) (20 + level * 2), "", (uintmax_t) offset,
230- known[op] ?: "???", *((int8_t *) data)++);
231+ known[op] ?: "???", *(int8_t *)data++);
232 --len;
233 offset += 2;
234 break;
235@@ -3090,7 +3090,7 @@
236 case DW_OP_consts:;
237 start = data;
238 unsigned int sleb;
239- get_sleb128 (sleb, ((unsigned char *) data));
240+ get_sleb128 (sleb, (unsigned char *)data);
241 printf (" %*s [%4" PRIuMAX "] %s %d\n",
242 (int) (20 + level * 2), "", (uintmax_t) offset,
243 known[op] ?: "???", sleb);
244@@ -3100,8 +3100,8 @@
245
246 case DW_OP_bregx:
247 start = data;
248- get_uleb128 (uleb, ((unsigned char *) data));
249- get_sleb128 (sleb, ((unsigned char *) data));
250+ get_uleb128 (uleb, (unsigned char *)data);
251+ get_sleb128 (sleb, (unsigned char *)data);
252 printf (" %*s [%4" PRIuMAX "] %s %u %d\n",
253 (int) (20 + level * 2), "", (uintmax_t) offset,
254 known[op] ?: "???", uleb, sleb);
This page took 0.097628 seconds and 4 git commands to generate.