forked from Ports/perfect_dark
Introduce ROM_SIZE Makefile option
This commit is contained in:
1 parent
46a88a3d59
commit
eb51ea4550
7 files changed
+40
-36
No files matched your search
+5
-1
@@ -40,13 +40,17 @@ void rom_load(char *filename)
|
||||
void rom_write(char *filename)
|
||||
{
|
||||
FILE *fp = fopen(filename, "wb");
|
||||
uint32_t fill_start;
|
||||
uint32_t rom_size;
|
||||
|
||||
if (!fp) {
|
||||
fprintf(stderr, "Unable to open \"%s\" for writing\n", filename);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
fwrite(state.rom, 1024 * 1024 * 32, 1, fp);
|
||||
map_get_segment_rompos("fill", &fill_start, &rom_size);
|
||||
|
||||
fwrite(state.rom, rom_size, 1, fp);
|
||||
fclose(fp);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user