Fixing makefiles I broke.
Various refactorings and reorganization.
Makefile fixed for real now.