Refactoring

Moved dependency checking to configure step.
Added more documentation.
Specify the mex files in the easyconfig to be more robust for changes.