diff options
-rw-r--r-- | .gitignore | 2 | ||||
-rw-r--r-- | Common.mk | 4 | ||||
-rwxr-xr-x | tests/test1.sh | 10 |
3 files changed, 13 insertions, 3 deletions
@@ -2,6 +2,6 @@ build/ obj/ mk.old Makefile -serial.log +*.log *.swp *.hda @@ -16,8 +16,8 @@ GDB = gdb-multiarch CFLAGS = -mcpu=cortex-a7 -fpic -ffreestanding -std=gnu99 -O3 -Wall -Wextra -nostdlib -Iinclude -g AFLAGS = -mcpu=cortex-a7 -Iinclude -g QFLAGS = -M raspi2b -cpu cortex-a7 -m 1G -QFLAGS += -chardev stdio,id=char0,mux=on,logfile=serial.log,signal=off -serial chardev:char0 -mon chardev=char0 -#QFLAGS += -serial pipe:/tmp/guest +#QFLAGS += -chardev stdio,id=char0,mux=on,logfile=serial.log,signal=off -serial chardev:char0 -mon chardev=char0 +QFLAGS += -chardev pipe,id=char0,mux=on,logfile=serial.log,path=guest -serial chardev:char0 -mon chardev=char0 QFLAGS += -device usb-kbd ifneq ("$(wildcard ./sd.hda)","") QFLAGS += -drive file=sd.hda,if=sd,format=raw diff --git a/tests/test1.sh b/tests/test1.sh new file mode 100755 index 0000000..2641953 --- /dev/null +++ b/tests/test1.sh @@ -0,0 +1,10 @@ +#!/bin/bash +pushd ./ +rm -f test1.log +make run & +cat guest.out >> test1.log & +sleep 1 +printf "ab" >> guest.in +sleep 2 +printf "\001x" >> guest.in +popd |