Moved files into lib
More adjustments.