Gameboy Development Forum

Discussion about software development for the old-school Gameboys, ranging from the "Gray brick" to Gameboy Color
(Launched in 2008)

You are not logged in.

Ads

#1 2026-01-03 17:47:58

talien
New member
Registered: 2026-01-03
Posts: 1

Linker error using both sdcc and rgbasm

I'm seeing a strange error when trying to link objects generated by sdcc using rgblink.
I'm not sure if this simply isn't supported or if I'm doing something wrong.

Compiling the below C code and linking with rgblink (even with only one linker input) and a basic linkerscript results in the error "FATAL: 'T' lines which don't append to their section are not supported (271 != 273)"

Removing the line marked "bad line" will make the error disappear.

Any insight would be appreciated!

Code:

const char some_text[] = "abcdefg\0";

extern void call_asm(char* text);

struct some_struct{
   char    x;
   char    y;
   const char  *text;   
};

void some_func(void){
    struct some_struct thing = {.x = 5, .y = 5, .text = some_text}; //<-- BAD LINE
    call_asm(some_text);
}

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2005 Rickard Andersson