Initial refactoring / LGPL tagging