Revert "Big update of CMakeLists.txt". This does not really work.

This reverts commit c8cb4bec4fa614116e492bfc974ac2ebb458fba3.