Closed leifo closed 2 years ago
The section name according to gcc8_c_support.h should work. Got a minimal repro case for me? I‘ll have a look.
Here is a test project: https://github.com/leifo/amiga-demolib/tree/master/gcc-vasm-sections (green screen if working, or only chip available, otherwise blue)
The problem was just the extraneous spaces around the section name
section ".INCBIN.MEMF_CHIP",data_c
works fine.
Here are all supported section name suffixes from elf2hunk
:
if(strcmp(nameext, ".MEMF_CHIP") == 0) {
hh[i]->memflags |= MEMF_CHIP;
} else if(strcmp(nameext, ".MEMF_LOCAL") == 0) {
hh[i]->memflags |= MEMF_LOCAL;
} else if(strcmp(nameext, ".MEMF_KICK") == 0) {
hh[i]->memflags |= MEMF_KICK;
} else if(strcmp(nameext, ".MEMF_FAST") == 0) {
hh[i]->memflags |= MEMF_FAST;
}
I'd like to define chip-section on the asm-side for convenience reasons for copperlists and bitplanes. I have already mixed this toolchain with vasm which can output ELF, generally works like a charm, but then cannot support memory attributes without the help of a patched linker (as far as I understand now after a message from phx), as the ELF-format does not support that.
Something like 'section chipram,data_c'. (I don't care for my sections names as long as they go to the right type of memory).
'section " .INCBIN.MEMF_CHIP ",data_c' (inspired by defines in gcc8_c_support.h) get's close but chokes the vscode-GDB connection with this error message: "Failed to launch GDB: TypeError: Cannot set property 'address' of undefined".
Could this be done?