Remove unused libs, clean up dir tree.