CLEANFILES = qemu-sanity-check
bin_SCRIPTS = qemu-sanity-check
+initrddir = $(libdir)/qemu-sanity-check
+initrd_DATA = initrd
+
+# Build the initramfs.
+initrd: init
+ echo $< | cpio --quiet -o -H newc > $@-t
+ mv $@-t $@
+
+noinst_PROGRAMS = init
+init_SOURCES = init.c
+init_CFLAGS = -static
+init_LDFLAGS = -static
+
+# Build the man pages.
+qemu-sanity-check.pod: qemu-sanity-check.pod.in Makefile
+ rm -f $@ $@-t
+ $(SED) -e 's,@libdir\@,$(libdir),g' < $< > $@-t
+ mv $@-t $@
+ chmod 0555 $@
if HAVE_POD2MAN
endif
-TESTS = qemu-sanity-check
+# Tests.
+TESTS = run-qemu-sanity-check