Make the OS file readonly, to prevent the "Text file busy" error (executed as a linux shell script + open for writing by another process)

This commit is contained in:
Georges Dupéron 2018-07-03 19:57:54 +02:00
parent 5d42b3e99f
commit f1b58e16c2
2 changed files with 3 additions and 2 deletions

View File

@ -8,8 +8,9 @@ all: $(os_filename) os.ndisasm.disasm os.reasm.asm os.reasm .gitignore test Make
mkdir -p $@
$(os_filename): os.asm ../deploy-screenshots Makefile
rm -f $@
nasm -o $@ $<
chmod a+x $@
chmod a+x-w $@
os.ndisasm.disasm: $(os_filename) Makefile
../utils/compact-ndisasm.sh $< $@

View File

@ -6,7 +6,7 @@ if test $# -ne 1 || test "$1" = '-h' -o "$1" = '--help'; then
fi
os_filename="$1"
qemu-system-i386 -drive format=raw,file=${os_filename},index=0,if=floppy &
qemu-system-i386 -drive format=raw,readonly,file=${os_filename},index=0,if=floppy &
pid=$!
runsikulix -r test/check-gradient.sikuli && exitcode=$? || exitcode=$?