AMICI-dev/AMICI

cmake: replace explicit checks for CMAKE_BUILD_TYPE

Closed this issue · 0 comments

In our CMakeLists.txt:

  • Don't change CMAKE_BUILD_TYPE from within CMakeLists.txt. This should be passed to cmake at configure-time instead. This will also fix #2442.
  • Don't check for CMAKE_BUILD_TYPE explicitly -- not compatible with multi-config generators
  • Set MAP_IMPORTED_CONFIG_CONFIG

See also https://cmake.org/cmake/help/latest/manual/cmake-buildsystem.7.html#build-configurations