another major restructure to simplify build process