Reorganize directory structure and Makefile.