obschan Posted March 8, 2012 Share Posted March 8, 2012 Hello, I am trying myself to some lynx dev. following the http://www.classicga...r%27s_Reference documentation. Sadly when I try to compile the first sample I am getting an awkward compilation error : $ cc65 -t lynx main.c /usr/local/lib/cc65/include/6502.h(117): Warning: Implicit `int' is an obsolete feature /usr/local/lib/cc65/include/6502.h(117): Error: `)' expected /usr/local/lib/cc65/include/6502.h(117): Error: `{' expected ... I tried under linux: compiling cc65, the .deb package, under Windows the binaries, and a compiled version under cygwin. I keep getting the same error. I there something wrong with the latest cc65 or am I missing something there ? Thank you. Quote Link to comment Share on other sites More sharing options...
Ninjabba Posted March 8, 2012 Share Posted March 8, 2012 I had that error too when I compiled an older project with the latest snapshot. Luckily, I could just remove the included 6502.h header and it compiled. No idea what causes it though.. When I switched to an older version (2.13.2) the error dissapeared. Quote Link to comment Share on other sites More sharing options...
GroovyBee Posted March 8, 2012 Share Posted March 8, 2012 Can you post line 117 in 6502.h? Quote Link to comment Share on other sites More sharing options...
obschan Posted March 8, 2012 Author Share Posted March 8, 2012 I had that error too when I compiled an older project with the latest snapshot. Luckily, I could just remove the included 6502.h header and it compiled. No idea what causes it though.. When I switched to an older version (2.13.2) the error dissapeared. Thank you Ninjabba, happy to see I am not the only one, did the same, got rid of the 6502.h Can you post line 117 in 6502.h? 114 : typedef unsigned char (*irq_handler) (void); 115 : /* Type of the C level interrupt request handler */ 117 : void __fastcall__ set_irq (irq_handler f, void *stack_addr, size_t stack_size); Quote Link to comment Share on other sites More sharing options...
+karri Posted March 11, 2012 Share Posted March 11, 2012 I looked into this problem. It is a recent bug. The runaround is to include stddef.h before 6502.h. #include <stddef.h> #include <6502.h> should work ok. - Karri 1 Quote Link to comment Share on other sites More sharing options...
+karri Posted March 11, 2012 Share Posted March 11, 2012 Actually now this cc65 bug is fixed in the svn repository. -- Karri 1 Quote Link to comment Share on other sites More sharing options...
Ninjabba Posted March 11, 2012 Share Posted March 11, 2012 Actually now this cc65 bug is fixed in the svn repository. -- Karri Hi Karri, is that optimization bug also fixed by any chance? Quote Link to comment Share on other sites More sharing options...
obschan Posted March 11, 2012 Author Share Posted March 11, 2012 Actually now this cc65 bug is fixed in the svn repository. Great, thank you Karri ! Quote Link to comment Share on other sites More sharing options...
GadgetUK Posted November 24, 2012 Share Posted November 24, 2012 Thanks for this, i've just hit the same problem and this fixed it! Was driving me nuts lol. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.