Added a bunch of preliminary bootstrap code