vhelin / wla-dx

WLA DX - Yet Another GB-Z80/Z80/Z80N/6502/65C02/65CE02/65816/68000/6800/6801/6809/8008/8080/HUC6280/SPC-700/SuperFX Multi Platform Cross Assembler Package
Other
549 stars 98 forks source link

Linking RAMSECTIONS with libraries #337

Closed Scryfox closed 3 years ago

Scryfox commented 3 years ago

Hello! I am trying to link a ramsection that is in a library, but I am getting an error wla-65816 -o main.o main.asm wla-65816 -l ./libraries/controllers.lib ./libraries/controllers.asm wlalink -v Linkfile main.sfc ./libraries/controllers.lib: ./libraries/controllers.asm: CHECK_RAMSECTIONS: RAM section "Controller Status" has no BANK/SLOT. Give them in the linkfile under [ramsections].

However, in my link file (below), I have placed the ramsection with a bank/slot as the documentation shows. If you could provide any guidance, I would really appreciate it!

[objects] main.o [libraries] bank 0 slot 2 ./libraries/controllers.lib [header] [footer] [ramsections] bank 0 slot 1 "Controller Status" [sections] [definitions]

Section in question

.RAMSECTION "Controller Status" FREE

    Joy1Raw         dw
    Joy1Press       dw
    Joy1Held        dw

.ENDS

Scryfox commented 3 years ago

I am dumb... I forgot to remove the reference to the file in main after moving it into a library... I really appreciate your hard work on this project though, it is really amazing!

vhelin commented 3 years ago

Hi! Good thing you found a solution to the problem. :) Sorry for the late reply, also... :P

I'm happy if you users find WLA DX useful! All improvement ideas are welcome.