Minor bugs fixed. Unused lib removed.