Makefile added.
Debug.
Unused var.
Clean up.
Bugfix.
Unused code removed.