mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-20 18:22:07 +00:00
Fix missing .sym/.map symbols in SECTION UNION/FRAGMENTs
Only the first "slice"'s symbols were considered, forgetting some symbols
This commit is contained in:
@@ -368,10 +368,16 @@ static uint16_t writeMapBank(struct SortedSections const *sectList,
|
|||||||
fprintf(mapFile, " SECTION: $%04" PRIx16 " (0 bytes) [\"%s\"]\n",
|
fprintf(mapFile, " SECTION: $%04" PRIx16 " (0 bytes) [\"%s\"]\n",
|
||||||
sect->org, sect->name);
|
sect->org, sect->name);
|
||||||
|
|
||||||
for (size_t i = 0; i < sect->nbSymbols; i++)
|
uint16_t org = sect->org;
|
||||||
fprintf(mapFile, " $%04" PRIx32 " = %s\n",
|
|
||||||
sect->symbols[i]->offset + sect->org,
|
while (sect) {
|
||||||
sect->symbols[i]->name);
|
for (size_t i = 0; i < sect->nbSymbols; i++)
|
||||||
|
fprintf(mapFile, " $%04" PRIx32 " = %s\n",
|
||||||
|
sect->symbols[i]->offset + org,
|
||||||
|
sect->symbols[i]->name);
|
||||||
|
|
||||||
|
sect = sect->nextu; // Also print symbols in the following "pieces"
|
||||||
|
}
|
||||||
|
|
||||||
*pickedSection = (*pickedSection)->next;
|
*pickedSection = (*pickedSection)->next;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user