You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The CMake build files currently set options using the add_compile_options function, which adds the respective argument independently from the actual build configuration (we call it profile in fpm).
For context: The CMake build configuration is found in CMAKE_BUILD_TYPE and is empty by default (NoConfig), other common profiles are Debug, RelWithDebInfo, Release, and MinSizeRel, but one can basically use any name. The global compiler options are taken from CMAKE_Fortran_FLAGS and the build configuration specific ones from CMAKE_Fortran_FLAGS_${CMAKE_BUILD_TYPE} (with the value of CMAKE_BUILD_TYPE as uppercase...).
As I understood @milancurcic the current options set with add_compile_options are the debug / development profile, but they are currently added for all build configurations. Instead we should try to set those options to the CMAKE_Fortran_FLAGS_DEBUG variable.
The text was updated successfully, but these errors were encountered:
The CMake build files currently set options using the
add_compile_options
function, which adds the respective argument independently from the actual build configuration (we call it profile in fpm).For context: The CMake build configuration is found in
CMAKE_BUILD_TYPE
and is empty by default (NoConfig
), other common profiles areDebug
,RelWithDebInfo
,Release
, andMinSizeRel
, but one can basically use any name. The global compiler options are taken fromCMAKE_Fortran_FLAGS
and the build configuration specific ones fromCMAKE_Fortran_FLAGS_${CMAKE_BUILD_TYPE}
(with the value ofCMAKE_BUILD_TYPE
as uppercase...).As I understood @milancurcic the current options set with
add_compile_options
are the debug / development profile, but they are currently added for all build configurations. Instead we should try to set those options to theCMAKE_Fortran_FLAGS_DEBUG
variable.The text was updated successfully, but these errors were encountered: