Add Makefile
Move code into modules