Revert "Merge pull request #309 from euanh/makefile-refactoring"

This reverts commit bf80f01b82c729eca2384c85f356f4e7c71b12ac, reversing
changes made to 25cd277308c9350b08290a0c0952843faa9d74d3.

Not quite ready yet...

Signed-off-by: Euan Harris <euan.harris@citrix.com>
Merge pull request #310 from euanh/makefile-refactoring

Revert "Merge pull request #309 from euanh/makefile-refactoring"