Merge pull request #317 from euanh/build-improvements

Refactor and tidy up Makefile / dependency generation
README: Fix typo

Signed-off-by: Euan Harris <euan.harris@citrix.com>