Fixe buildfile

Added dependencies and some niceties for building.