main CMakeLists.txt improved