Adding .param SWSOA=1 right after the .lib entry during reading in

the libraries.
This commit is contained in:
Holger Vogt 2025-07-23 16:51:55 +02:00
parent b1f4f32b36
commit 7fc68c0c07
1 changed files with 5 additions and 1 deletions

View File

@ -3966,8 +3966,12 @@ static void expand_section_references(struct card *c, const char *dir_name)
fprintf(stdout, "\nLibrary\n%s\nsaved to %s\n", p->line + 9, filename);
tfree(filename);
}
else if (ciprefix(".lib", c->line))
else if (ciprefix(".lib", c->line)) {
/* add SOA check info direcly after inserting the library */
if (cp_getvar("soacheck", CP_BOOL, NULL, 0))
insert_new_line(c, copy(".param SWSOA=1"), c->linenum + 1, 0, "internal");
c = expand_section_ref(c, dir_name);
}
}
}