Added makefile and dealt with compiler warnings.
Made a singleton session that can serve as a context for deduction.