build "core init test/lemon"

create_boot_directory

install_config {
<config>
	<parent-provides>
		<service name="ROM"/>
		<service name="RAM"/>
		<service name="IRQ"/>
		<service name="IO_MEM"/>
		<service name="IO_PORT"/>
		<service name="CAP"/>
		<service name="PD"/>
		<service name="RM"/>
		<service name="CPU"/>
		<service name="LOG"/>
	</parent-provides>
	<default-route>
		<any-service> <parent/> <any-child/> </any-service>
	</default-route>
	<default caps="100" />
	<start name="test-lemon">
		<resource name="RAM" quantum="2M"/>
		<config>
			<libc stdin="/dev/null" stdout="/dev/log" stderr="/dev/log"/>
			<vfs> <dir name="dev"> <log/> <null/> </dir>	</vfs>
		</config>
	</start>
</config>
}

build_boot_image {
	core init test-lemon
	ld.lib.so libc.lib.so vfs.lib.so posix.lib.so libm.lib.so stdcxx.lib.so
}

append qemu_args " -nographic  "

run_genode_until "child \"test-lemon\" exited with exit value 0" 20

