Makefile cleanup and reorganization