1 |
vostorga 09/10/26 16:26:20 |
2 |
|
3 |
Added: flasm-1.62-makefile.patch flasm-1.62-bison-2.patch |
4 |
Removed: flasm-1.6.2-makefile.patch |
5 |
flasm-1.6.2-bison-2.patch |
6 |
Log: |
7 |
Fixing version number from 1.6.2 to 1.62 bug #276451 |
8 |
(Portage version: 2.1.6.13/cvs/Linux i686) |
9 |
|
10 |
Revision Changes Path |
11 |
1.1 app-misc/flasm/files/flasm-1.62-makefile.patch |
12 |
|
13 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-misc/flasm/files/flasm-1.62-makefile.patch?rev=1.1&view=markup |
14 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-misc/flasm/files/flasm-1.62-makefile.patch?rev=1.1&content-type=text/plain |
15 |
|
16 |
Index: flasm-1.62-makefile.patch |
17 |
=================================================================== |
18 |
--- Makefile.old 2005-10-14 02:11:53.000000000 +0200 |
19 |
+++ Makefile 2006-10-27 22:59:55.654125000 +0200 |
20 |
@@ -1,6 +1,4 @@ |
21 |
UNAME = $(shell uname) |
22 |
-CC = gcc |
23 |
-CFLAGS = -g -Wall -O2 |
24 |
LIBS = -lz |
25 |
OFILES = util.o keywords.o flasm.o unflasm.o lex.yy.o assembler.tab.o |
26 |
GARBAGE = assembler.tab.* lex.yy.c memwatch.o gmon.out memwatch.log core |
27 |
@@ -9,8 +7,6 @@ |
28 |
ifneq (,$(findstring debug,$(MAKECMDGOALS))) |
29 |
CFLAGS += -DMEMWATCH -pg -p -pedantic -W -Wcast-align -Wcast-qual -Wshadow -Wnested-externs -Wstrict-prototypes -Waggregate-return -Wmissing-prototypes -Wpointer-arith |
30 |
OFILES += memwatch.o |
31 |
-else |
32 |
- CFLAGS += -s |
33 |
endif |
34 |
|
35 |
# executable should not depend on cygwin.dll |
36 |
@@ -26,7 +22,7 @@ |
37 |
-rm -f ${OFILES} ${GARBAGE} |
38 |
|
39 |
flasm: ${OFILES} |
40 |
- ${CC} $(CFLAGS) -o flasm ${OFILES} ${LIBS} |
41 |
+ ${CC} $(CFLAGS) $(LDFLAGS) -o flasm ${OFILES} ${LIBS} |
42 |
|
43 |
assembler.tab.c assembler.tab.h: assembler.y |
44 |
bison --defines --debug assembler.y |
45 |
|
46 |
|
47 |
|
48 |
1.1 app-misc/flasm/files/flasm-1.62-bison-2.patch |
49 |
|
50 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-misc/flasm/files/flasm-1.62-bison-2.patch?rev=1.1&view=markup |
51 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-misc/flasm/files/flasm-1.62-bison-2.patch?rev=1.1&content-type=text/plain |
52 |
|
53 |
Index: flasm-1.62-bison-2.patch |
54 |
=================================================================== |
55 |
diff -up flasm-1.62/assembler.y.midrule flasm-1.62/assembler.y |
56 |
--- flasm-1.62/assembler.y.midrule 2008-12-20 22:44:50.000000000 +0100 |
57 |
+++ flasm-1.62/assembler.y 2008-12-20 22:54:03.000000000 +0100 |
58 |
@@ -605,24 +605,24 @@ finally_opt |
59 |
|
60 |
trycatchfinally |
61 |
: TRY name_opt { |
62 |
- $$ = writeByte(SWFACTION_TRY); |
63 |
+ $<num>$ = writeByte(SWFACTION_TRY); |
64 |
/* action length */ |
65 |
- $$ += writeShort(strlen($2)+8); |
66 |
+ $<num>$ += writeShort(strlen($2)+8); |
67 |
/* zero flag */ |
68 |
- $$ += writeByte(0); |
69 |
+ $<num>$ += writeByte(0); |
70 |
/* zero try length */ |
71 |
- $$ += writeShort(0); |
72 |
+ $<num>$ += writeShort(0); |
73 |
/* zero catch length */ |
74 |
- $$ += writeShort(0); |
75 |
+ $<num>$ += writeShort(0); |
76 |
/* zero finally length */ |
77 |
- $$ += writeShort(0); |
78 |
+ $<num>$ += writeShort(0); |
79 |
/* error variable name */ |
80 |
- $$ += writeString($2); |
81 |
+ $<num>$ += writeString($2); |
82 |
} |
83 |
|
84 |
- statements_opt { $$ = $<num>3 + $4; patchLength($$ - 6, $4); } |
85 |
- catch_opt { $$ = $<num>5 + $6; patchLength($$ - 8, $6); } |
86 |
- finally_opt { $$ = $<num>7 + $8; patchLength($$ - 10, $8); } |
87 |
+ statements_opt { $<num>$ = $<num>3 + $4; patchLength($<num>$ - 6, $4); } |
88 |
+ catch_opt { $<num>$ = $<num>5 + $6; patchLength($<num>$ - 8, $6); } |
89 |
+ finally_opt { $<num>$ = $<num>7 + $8; patchLength($<num>$ - 10, $8); } |
90 |
END { |
91 |
byte flag = 0; |
92 |
$$ = $<num>9; |
93 |
@@ -634,24 +634,24 @@ trycatchfinally |
94 |
} |
95 |
|
96 |
| TRY register { |
97 |
- $$ = writeByte(SWFACTION_TRY); |
98 |
+ $<num>$ = writeByte(SWFACTION_TRY); |
99 |
/* action length */ |
100 |
- $$ += writeShort(8); |
101 |
+ $<num>$ += writeShort(8); |
102 |
/* zero flag */ |
103 |
- $$ += writeByte(0); |
104 |
+ $<num>$ += writeByte(0); |
105 |
/* zero try length */ |
106 |
- $$ += writeShort(0); |
107 |
+ $<num>$ += writeShort(0); |
108 |
/* zero catch length */ |
109 |
- $$ += writeShort(0); |
110 |
+ $<num>$ += writeShort(0); |
111 |
/* zero finally length */ |
112 |
- $$ += writeShort(0); |
113 |
+ $<num>$ += writeShort(0); |
114 |
/* error register number */ |
115 |
- $$ += writeByte((byte) $2); |
116 |
+ $<num>$ += writeByte((byte) $2); |
117 |
} |
118 |
|
119 |
- statements_opt { $$ = $<num>3 + $4; patchLength($$ - 6, $4); } |
120 |
- catch_opt { $$ = $<num>5 + $6; patchLength($$ - 8, $6); } |
121 |
- finally_opt { $$ = $<num>7 + $8; patchLength($$ - 10, $8); } |
122 |
+ statements_opt { $<num>$ = $<num>3 + $4; patchLength($<num>$ - 6, $4); } |
123 |
+ catch_opt { $<num>$ = $<num>5 + $6; patchLength($<num>$ - 8, $6); } |
124 |
+ finally_opt { $<num>$ = $<num>7 + $8; patchLength($<num>$ - 10, $8); } |
125 |
END { |
126 |
byte flag = 4; |
127 |
$$ = $<num>9; |
128 |
@@ -707,25 +707,25 @@ name_opt |
129 |
|
130 |
function |
131 |
: FUNCTION name_opt { |
132 |
- $$ = writeByte(SWFACTION_DEFINEFUNCTION); |
133 |
+ $<num>$ = writeByte(SWFACTION_DEFINEFUNCTION); |
134 |
/* zero block length */ |
135 |
- $$ += writeShort(0); |
136 |
- $$ += writeString($2); |
137 |
+ $<num>$ += writeShort(0); |
138 |
+ $<num>$ += writeString($2); |
139 |
} |
140 |
|
141 |
'(' function_args ')' { |
142 |
unsigned int i; |
143 |
numArgs = $5; |
144 |
|
145 |
- $$ = $<num>3 + writeShort(numArgs); |
146 |
+ $<num>$ = $<num>3 + writeShort(numArgs); |
147 |
|
148 |
for(i = 0; i < numArgs; ++i) |
149 |
- $$ += writeString(func_args[i]); |
150 |
+ $<num>$ += writeString(func_args[i]); |
151 |
|
152 |
/* zero function length */ |
153 |
- $$ += writeShort(0); |
154 |
+ $<num>$ += writeShort(0); |
155 |
/* patch block length */ |
156 |
- patchLength($$-3, $$-3); |
157 |
+ patchLength($<num>$-3, $<num>$-3); |
158 |
} |
159 |
|
160 |
statements_opt END { |
161 |
@@ -837,25 +837,25 @@ autoregarglist |
162 |
|
163 |
function2 |
164 |
: FUNCTION2 name_opt { |
165 |
- $$ = writeByte(SWFACTION_DEFINEFUNCTION2); |
166 |
+ $<num>$ = writeByte(SWFACTION_DEFINEFUNCTION2); |
167 |
/* zero block length */ |
168 |
- $$ += writeShort(0); |
169 |
+ $<num>$ += writeShort(0); |
170 |
/* function name */ |
171 |
- $$ += writeString($2); |
172 |
+ $<num>$ += writeString($2); |
173 |
curFunc++; |
174 |
memset(regfunc_args[curFunc], 0, sizeof (regfunc_args[curFunc])); |
175 |
numArgs = 0; |
176 |
/* zero num of function arguments */ |
177 |
- $$ += writeShort(numArgs); |
178 |
+ $<num>$ += writeShort(numArgs); |
179 |
/* allocate zero registers */ |
180 |
numRegisters[curFunc] = 0; |
181 |
- $$ += writeByte(numRegisters[curFunc]); |
182 |
+ $<num>$ += writeByte(numRegisters[curFunc]); |
183 |
/* zero automatic register flags */ |
184 |
- $$ += writeShort(0); |
185 |
+ $<num>$ += writeShort(0); |
186 |
} |
187 |
|
188 |
'(' regarglist ')' { |
189 |
- $$ = $<num>3 + $5; |
190 |
+ $<num>$ = $<num>3 + $5; |
191 |
/* patch num of function arguments */ |
192 |
patchLength($5 + 3, numArgs); |
193 |
autoregFlags = 0; |
194 |
@@ -866,9 +866,9 @@ function2 |
195 |
byte curautoreg = 1; |
196 |
unsigned int i; |
197 |
|
198 |
- $$ = $<num>7; |
199 |
+ $<num>$ = $<num>7; |
200 |
/* zero body length */ |
201 |
- $$ += writeShort(0); |
202 |
+ $<num>$ += writeShort(0); |
203 |
|
204 |
/* make sure auto registers are allocated in the right order */ |
205 |
for (i = 0; i < MAX_AUTO_REGS; i++) { |
206 |
@@ -883,9 +883,9 @@ function2 |
207 |
} |
208 |
|
209 |
/* patch automatic register flags */ |
210 |
- patchLength($$ - $<num>3, autoregFlags); |
211 |
+ patchLength($<num>$ - $<num>3, autoregFlags); |
212 |
/* patch block length */ |
213 |
- patchLength($$ - 3, $$ - 3); |
214 |
+ patchLength($<num>$ - 3, $<num>$ - 3); |
215 |
} |
216 |
|
217 |
statements_opt END { |
218 |
@@ -905,11 +905,11 @@ function2 |
219 |
|
220 |
with |
221 |
: WITH { |
222 |
- $$ = writeByte(SWFACTION_WITH); |
223 |
+ $<num>$ = writeByte(SWFACTION_WITH); |
224 |
/* length of with action */ |
225 |
- $$ += writeShort(2); |
226 |
+ $<num>$ += writeShort(2); |
227 |
/* length of with block - will be patched */ |
228 |
- $$ += writeShort(0); |
229 |
+ $<num>$ += writeShort(0); |
230 |
} |
231 |
|
232 |
statements_opt END { |
233 |
@@ -921,9 +921,9 @@ with |
234 |
|
235 |
settarget |
236 |
: SETTARGET STRING { |
237 |
- $$ = writeByte(SWFACTION_SETTARGET); |
238 |
- $$ += writeShort(strlen($2)+1); |
239 |
- $$ += writeString($2); |
240 |
+ $<num>$ = writeByte(SWFACTION_SETTARGET); |
241 |
+ $<num>$ += writeShort(strlen($2)+1); |
242 |
+ $<num>$ += writeString($2); |
243 |
} |
244 |
|
245 |
statements_opt END { |
246 |
@@ -934,7 +934,7 @@ settarget |
247 |
; |
248 |
|
249 |
settargetexpression |
250 |
- : SETTARGETEXPR { $$ = writeByte(SWFACTION_SETTARGETEXPRESSION); } |
251 |
+ : SETTARGETEXPR { $<num>$ = writeByte(SWFACTION_SETTARGETEXPRESSION); } |
252 |
statements_opt END { |
253 |
$$ = $3 + writeByte(SWFACTION_SETTARGET); |
254 |
$$ += $<num>2 + writeShort(1); |
255 |
@@ -946,9 +946,9 @@ ifframeloadedexpression |
256 |
: IFFRAMELOADEDEXPR { |
257 |
if (frameloadedStart>-1) |
258 |
yyerror("IfFrameLoaded actions can't be nested"); |
259 |
- $$ = writeByte(SWFACTION_IFFRAMELOADEDEXPRESSION); |
260 |
- $$ += writeShort(1); |
261 |
- $$ += writeByte(0); |
262 |
+ $<num>$ = writeByte(SWFACTION_IFFRAMELOADEDEXPRESSION); |
263 |
+ $<num>$ += writeShort(1); |
264 |
+ $<num>$ += writeByte(0); |
265 |
frameloadedStart = numActions; |
266 |
} |
267 |
|
268 |
@@ -963,10 +963,10 @@ ifframeloaded |
269 |
: IFFRAMELOADED INTEGER { |
270 |
if (frameloadedStart>-1) |
271 |
yyerror("IfFrameLoaded actions can't be nested"); |
272 |
- $$ = writeByte(SWFACTION_IFFRAMELOADED); |
273 |
- $$ += writeShort(3); |
274 |
- $$ += writeShort($2); |
275 |
- $$ += writeByte(0); |
276 |
+ $<num>$ = writeByte(SWFACTION_IFFRAMELOADED); |
277 |
+ $<num>$ += writeShort(3); |
278 |
+ $<num>$ += writeShort($2); |
279 |
+ $<num>$ += writeByte(0); |
280 |
frameloadedStart = numActions; |
281 |
} |
282 |
|
283 |
@@ -1199,9 +1199,9 @@ opcode |
284 |
constant_list_opt { $$ = writeConstants(); } |
285 |
|
286 |
| PUSH { |
287 |
- $$ = writeByte(SWFACTION_PUSHDATA); |
288 |
+ $<num>$ = writeByte(SWFACTION_PUSHDATA); |
289 |
/* length */ |
290 |
- $$ += writeShort(0); |
291 |
+ $<num>$ += writeShort(0); |
292 |
} |
293 |
|
294 |
push_list { |
295 |
@@ -1212,10 +1212,10 @@ opcode |
296 |
| SWFACTION HEX { |
297 |
if (xtoi($2)>0xff) |
298 |
yyerror("Action code out of range"); |
299 |
- $$ = writeByte((char)xtoi($2)); |
300 |
+ $<num>$ = writeByte((char)xtoi($2)); |
301 |
if (xtoi($2)>=0x80) |
302 |
/* length */ |
303 |
- $$ += writeShort(0); |
304 |
+ $<num>$ += writeShort(0); |
305 |
} |
306 |
|
307 |
hexlist_opt { |