Bernhard Held wrote:
>>2. When I multiply ints ( int a, b, c; a = b*c; ), I get the message:
>> ?ASlink-Warning-Undefined Global __mulsint_rrx_s referenced by
>>It seems mulsint_rrx_s isn't defined in the sdcc libraries; I only found
>>mulint_rrx_s in lib/src/z80/mul.s.
>You obviously are mixing different "versions" of sdcc. The current sdcc
>doesn't call mulsint_rrx_s, and consequently it's not defined in the libs.
Hm, I'm pretty sure I'm not mixing versions... but I did something else
which doesn't seem to be a good idea in retrospect: I moved sdcc.exe
somewhere else. My rationale behind this (and behind the --nostdlib) is
that I'm writing code for an embedded platform, and I thought I just
needed a compiler, without any libs. I didn't take into account that
sdcc needs its libs for multiplications etc.
To clarify: Is it correct that, even without --nostdlib, sdcc only
includes library methods that are needed for the application? Then I can
happily omit --nostdlib...
> I don't understand, why you use --nostdlib. Please omit it,
>and we all have less problems :->
...as you suggest .
Duh, I just tried to compile my code without --nostdlib - and it worked
fine. Silly me :-)
Oh, one tiny thing: the --no-std-crt0 option suggested by Jesus
Calvino-Fraga doesn't show any effect (the warning still appears). But
since the option is just a workaround, it doesn't really matter.
Many thanks for your help,