Overall cleanup, made more DRY code. Added detection of Mongo and Sphinx dependencies. Added TODO in comments.

Signed-off-by: Daniel (dmilith) Dettlaff <dmilith@verknowsys.com>