Update Makefile-s.
Move API files into api.
Rearrange files.