mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-22 03:02:06 +00:00
Add overlay file option to rgblink (-O)
This option takes a file and places fixed sections on top of it. Should prove useful for patches and partial disassemblies.
This commit is contained in:
@@ -35,8 +35,8 @@ static void
|
||||
usage(void)
|
||||
{
|
||||
printf(
|
||||
"usage: rgblink [-t] [-m mapfile] [-n symfile] [-o outfile] [-p pad_value]\n"
|
||||
" [-s symbol] file [...]\n");
|
||||
"usage: rgblink [-t] [-m mapfile] [-n symfile] [-O overlay] [-o outfile] \n"
|
||||
" [-p pad_value] [-s symbol] file [...]\n");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
@@ -56,7 +56,7 @@ main(int argc, char *argv[])
|
||||
|
||||
progname = argv[0];
|
||||
|
||||
while ((ch = getopt(argc, argv, "m:n:o:p:s:t")) != -1) {
|
||||
while ((ch = getopt(argc, argv, "m:n:o:O:p:s:t")) != -1) {
|
||||
switch (ch) {
|
||||
case 'm':
|
||||
SetMapfileName(optarg);
|
||||
@@ -67,6 +67,10 @@ main(int argc, char *argv[])
|
||||
case 'o':
|
||||
out_Setname(optarg);
|
||||
break;
|
||||
case 'O':
|
||||
out_SetOverlayname(optarg);
|
||||
options |= OPT_OVERLAY;
|
||||
break;
|
||||
case 'p':
|
||||
fillchar = strtoul(optarg, &ep, 0);
|
||||
if (optarg[0] == '\0' || *ep != '\0') {
|
||||
|
||||
Reference in New Issue
Block a user