Revert "Restructure build system"

This reverts commit 679719b5de6ee61c2c0e62aba3a4559d9dcbeaea.