Plumb through more of the syscalls; update headers; export do_fork.