build: Wait OSv to start up before uploading

This changes Capstan to use the same method as run.py for uploading. The
build command will launch QEMU and wait for cpiod.so to print out:

  Waiting for connection from host...

before starting the CPIO upload.

Signed-off-by: Pekka Enberg <penberg@cloudius-systems.com>