colobot/colobot — pull request #102 by OdyX (2012-12-19 16:06:16+00:00)
Title: Fix CMake flags handling

As explained in the commits, there are two problems:

1) it is not possible to override (at compile time) the CMAKE_BUILD_TYPE;

2) redundantly putting the "common" flags in both CMAKE_CXX_FLAGS_RELEASE and CMAKE_CXX_FLAGS_DEBUG doesn't really scale. And doesn't work if you use a non-Release, non-Debug build-type;

Also I'm not sure I understand why this logic is duplicated all over the CMakeLists.txt's : could that not be simply dropped (and overriden in the cases where it is necessary) ?