host/lib: add a subprocess library

This is a powerful library for interacting with processes. We'll be
able to clean up much of the code which manually sets up the pipes and
calls exec* with this well-tested and expressive abstraction.

This code will initially be used in crossystem for calling out to
flashrom instead of relying on mosys.

BUG=chromium:1030473
BRANCH=none
TEST=provided unit tests

Change-Id: I56f28419406d0b1299bb91058dd4500079b2435e
Signed-off-by: Jack Rosenthal <jrosenth@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/vboot_reference/+/1955805
Reviewed-by: Julius Werner <jwerner@chromium.org>
Reviewed-by: Joel Kitching <kitching@chromium.org>
4 files changed