Page 1 of 1

Error at file 'w5100.c' line 330: symbol 'l_asr_u_hl_by_e' not defined

Posted: Tue Mar 26, 2019 7:37 pm
by jacotton
This popped up last night. Real stumper until I looked as the c/asm file.

This is what the offending line of text looks like.

Error at file 'w5100.c' line 264: symbol 'l_asr_u_hl_by_e' not defined
^ ---- cmd[2] = ((addr >> 3) & 0xe0) | 0x0c;

addr is unsigned int and cmd is unsigned char

to fix this I added
GLOBAL l_asr_u_hl_by_e

to the front of the c source file.

Here is the compile command.

zcc +cpm -O3 -vn -s -m --list -create-app --c-code-in-asm -no-cleanup -odriver -D_DHCP_DEBUG_ main.c spi.c ethernet.c w5100.c dhcp.c

Posted: Tue Mar 26, 2019 9:08 pm
by dom
That's really odd, it was added in change bac837e4d0f7ea768f7d1660aecf45b788131d5e back in March 2018.

It's defined in lib/z80_crt0.hdr which is included in every compiled file so I'm really not sure why it's reporting an error unless your install is a bit wonky or there's a bad typo somewhere - can you point me to your source so I can see if I can reproduce it?