summaryrefslogtreecommitdiffstats
path: root/Makefile.am
diff options
context:
space:
mode:
authorRichard Jones <rjones@redhat.com>2009-04-01 16:08:23 +0100
committerRichard Jones <rjones@redhat.com>2009-04-01 16:08:23 +0100
commitfddf794d1a4446c94f652af4eeba37a599355e6f (patch)
tree567dc74dce779944ac015894e3f98f7aab2a3510 /Makefile.am
parentfe6820c1bbaec015a883804545362a8c9b6b4583 (diff)
downloadlibguestfs-fddf794d1a4446c94f652af4eeba37a599355e6f.tar.gz
libguestfs-fddf794d1a4446c94f652af4eeba37a599355e6f.tar.xz
libguestfs-fddf794d1a4446c94f652af4eeba37a599355e6f.zip
Add test-boot-realistic target.
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am26
1 files changed, 21 insertions, 5 deletions
diff --git a/Makefile.am b/Makefile.am
index 154347f3..7054ea84 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -44,19 +44,35 @@ initramfs.timestamp: make-initramfs.sh.in daemon/guestfsd
# Make clean.
-CLEANFILES = $(fs_DATA) initramfs.timestamp
+CLEANFILES = $(fs_DATA) initramfs.timestamp emptydisk
clean-local:
rm -rf initramfs
# Test-boot the image.
-test-boot-image:
+test-boot: emptydisk
+ qemu-system-$(host_cpu) \
+ -m 384 \
+ -kernel $(VMLINUZ) -initrd $(INITRAMFSIMG) \
+ -hda emptydisk
+
+emptydisk:
rm -f emptydisk
dd if=/dev/zero of=emptydisk bs=1024 count=1440
- echo 0, | sfdisk -C 80 -H 2 -S 18 emptydisk
+ echo 0, | sfdisk -q -C 80 -H 2 -S 18 emptydisk > /dev/null
+
+# This is a more realistic test boot command line which better
+# reflects what the library does.
+
+test-boot-realistic: emptydisk
qemu-system-$(host_cpu) \
-m 384 \
-kernel $(VMLINUZ) -initrd $(INITRAMFSIMG) \
- -hda emptydisk -boot c
- rm -f emptydisk
+ -hda emptydisk \
+ -append "console=ttyS0 guestfs=10.0.2.4:6666" \
+ -nographic \
+ -serial stdio \
+ -net channel,6666:unix:/tmp/sock,server,nowait \
+ -net user,vlan=0 \
+ -net nic,vlan=0