This commit is contained in:
Romain Dolbeau 2022-10-06 23:54:24 +02:00
parent d29ac5bd65
commit fa39c042d1
2 changed files with 33 additions and 32 deletions

View File

@ -33,7 +33,7 @@ ${GEN_ASM}: gen_mode
all: vid_decl_rom.bin
vid_decl_rom.o: vid_decl_rom.s NuBusFPGAPrimaryInit.s NuBusFPGASecondaryInit.s NuBusFPGADrvr.s ${APPLEINCS} DepVideo.inc ${GEN_ASM}
vid_decl_rom.o: vid_decl_rom.s NuBusFPGADrvr.s NuBusFPGARAMDskDrvr.s ${APPLEINCS} DepVideo.inc ${GEN_ASM}
rm -f res.inc
echo -e "HRES=${HRES}\nVRES=${VRES}\n" | tee res.inc
${AS} ${ARCHFLAGS} -I${NS816DECLROMDIR} $< -o $@ -a > vid_decl_rom.l

View File

@ -71,13 +71,15 @@ int main(int argc, char **argv) {
if (res_db[i].native_only && ((hres != maxhres) || (vres != maxvres)))
continue;
if ((hres > maxhres) || (vres > maxvres))
continue;
snprintf(filename, 512, "VidRomRes_%hux%hu.s", hres, vres);
fd = fopen(filename, "w");
if (fd == NULL) {
fprintf(stderr, "Generating '%s' failed.\n", filename);
return -1;
}
if ((hres <= maxhres) && (vres <= maxvres)) {
enabled[i] = 1;
id ++;
@ -110,7 +112,6 @@ int main(int argc, char **argv) {
fprintf(fd, "\t.long\t0\t/* bmPlaneBytes */\n"); // defmPlaneBytes
fprintf(fd, "_End%sParms:\n\n",modename);
}
}
fclose(fd);
}