From d7778ecaef3a1f31186045bf0c4fc9a0284ff4dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wolfgang=20M=C3=BCller?= Date: Tue, 7 Sep 2021 20:34:01 +0200 Subject: [PATCH] Introduce project-specific dosbox.conf With the stock configuration, DOSBox limits the amount of instructions it emulates each millisecond to a value it guesses. This is a reasonable default to have when emulating games or other software from the time, but woefully slow for our purposes of compilation. Since the user's configuration file will most likely be tailored to other uses, it makes sense, then, to use a project-specific configuration here and override any user configuration. For now, set only the cycles setting to 'max'. The DOSBox invocation in the Makefile gets a bit long with the addition of the -conf flag, so contain it in a variable instead. --- Makefile | 10 ++++++---- dosbox.conf | 2 ++ 2 files changed, 8 insertions(+), 4 deletions(-) create mode 100644 dosbox.conf diff --git a/Makefile b/Makefile index bb079c6..6ba68e5 100644 --- a/Makefile +++ b/Makefile @@ -1,3 +1,5 @@ +DOSBOX=dosbox -conf dosbox.conf -exit + ordos.img: BOOT.BIN IO.SYS ORDOS.SYS COMMAND.COM debug.com edlin.com exe2bin.exe link.exe masm.exe rm -f ordos.img mkfs.fat -C $@ -M 0xff 320 @@ -12,16 +14,16 @@ ordos.img: BOOT.BIN IO.SYS ORDOS.SYS COMMAND.COM debug.com edlin.com exe2bin.exe mcopy -i $@ masm.exe :: BOOT.BIN: boot.asm - dosbox -exit mk-boot.bat + $(DOSBOX) mk-boot.bat IO.SYS: io.asm - dosbox -exit mk-io.bat + $(DOSBOX) mk-io.bat ORDOS.SYS: msdos.asm stddos.asm - dosbox -exit mk-ordos.bat + $(DOSBOX) mk-ordos.bat COMMAND.COM: command.asm - dosbox -exit mk-comma.bat + $(DOSBOX) mk-comma.bat clean: rm -f ordos.img *.OBJ *.EXE *.COM *.BIN *.SYS diff --git a/dosbox.conf b/dosbox.conf new file mode 100644 index 0000000..bdaaa83 --- /dev/null +++ b/dosbox.conf @@ -0,0 +1,2 @@ +[cpu] +cycles=max