Refactored the tests for the makefile existence in a separate function. Ran checkdoc and fixed errors.