
Howdy, I want to compile ppcboot 1.1.6 by ELDK 4.1. Well, ppcboot is very ancient code, but for some reason, I have to compile it. There are many exact same compile-time errors reported: error: lvalue required as increment/decrement operand. xsum += *((ushort *)ptr)++;
*((ulong *)addr_sp)-- = 0;
...
There are about 20 errors. Is there any walkaround? eg, compile options to gcc that can use old C standard.
Again, a very obscure code: viod some_func(ushort* ptr,...) { ... switch(SWAP16(*((ushort *)ptr)++) // @_@ how to deal with the side-effect of ++? { case ...: ptr2 = ptr; // ptr is ++-ed of to-be ++ ? CallSomeOtherFunction(); // When calling, how about ptr.... ... } }
Thank you for your attention. --- ShenLei