refactored cmake files