This commit is contained in:
2023-11-05 20:03:00 +08:00
parent c5ccbb8d6d
commit a3c54c48fe
4 changed files with 93 additions and 0 deletions

12
build.sh Executable file
View File

@@ -0,0 +1,12 @@
#!/bin/bash
#cd `dirname $0`
bin=$1
nasm -f bin $1 -o `basename $1`.bin
if [[ $? != 0 ]];then
exit
fi
sudo modprobe nbd 8
sudo qemu-nbd `dirname $0`/test.qcow2 --connect /dev/nbd0
sudo dd if=`basename $1`.bin of=/dev/nbd0
sudo qemu-nbd -d /dev/nbd0
kvm --hda `dirname $0`/test.qcow2 -rtc base=localtime