Per conversation last week with Rich and Matt, while we want to have a
Guestconv C API which is relatively easy to bind to across different
languages, for the sake of expediency we want to the do the actual work
in Python.
The idea is that the C API will spawn a python process when
guestconv_create is called and ultimately be responsible for terminating
the process. Communication between the two process happens over pipe(2).
From the Python perspective, we will simply listen on stdin for
"commands" (there will be a command per API call: guestconv_add_drive,
guestconv_root, and guestconv_convert) and write the results to stdout.
Does that sound good to the list? Of course, we'll need to define what
exactly what the stdin/stdout interface looks like, but that will be
straightforward given the C API.
Thanks,
--Crag
Ref:
https://www.redhat.com/archives/libguestfs/2013-February/msg00107.html