diff --git a/CMakeLists.txt b/CMakeLists.txt index 5436f9cb1..248d8b49e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -13,7 +13,7 @@ project( get_directory_property(hasParent PARENT_DIRECTORY) if(hasParent) - # Unset flags that come from Parent (ie UFS or other coupled build) + # Unset flags that come from Parent (ie UFS or other coupled build) # for potential (-r8/-r4) conflict set(CMAKE_Fortran_FLAGS "") set(CMAKE_C_FLAGS "") @@ -22,7 +22,7 @@ endif() set(MULTI_ESMF OFF CACHE BOOL "Build ww3_multi_esmf library") set(NETCDF ON CACHE BOOL "Build NetCDF programs (requires NetCDF)") -set(ENDIAN "BIG" CACHE STRING "Endianness of unformatted output files. Valid values are 'BIG', 'LITTLE', 'NATIVE'.") +set(ENDIAN "BIG" CACHE STRING "Endianness of unformatted output files. Valid values are 'BIG', 'LITTLE', 'NATIVE'.") set(EXCLUDE_FIND "" CACHE STRING "Don't try and search for these libraries (assumd to be handled by the compiler/wrapper)") # make sure all "exclude_find" entries are lower case @@ -51,9 +51,16 @@ configure_file(${switch_file} ${CMAKE_BINARY_DIR}/switch COPYONLY) # Re-configure CMake when switch changes set_property(DIRECTORY APPEND PROPERTY CMAKE_CONFIGURE_DEPENDS ${CMAKE_BINARY_DIR}/switch) -if(NOT CMAKE_BUILD_TYPE MATCHES "^(Debug|Release|RelWithDebInfo|MinSizeRel)$") - message(STATUS "Setting build type to 'Release' as none was specified.") - set(CMAKE_BUILD_TYPE "Release" CACHE STRING "Build type" FORCE) +# ##MTM +# if(NOT CMAKE_BUILD_TYPE MATCHES "^(Debug|Release|RelWithDebInfo|MinSizeRel)$") +# message(STATUS "Setting build type to 'Release' as none was specified.") +# set(CMAKE_BUILD_TYPE "Release" CACHE STRING "Build type" FORCE) +# set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug" "Release" "MinSizeRel" "RelWithDebInfo") +# endif() +# ##MTM +if(NOT CMAKE_BUILD_TYPE MATCHES "Debug") + message(STATUS "Setting build type to 'Debug' as none was specified.") + set(CMAKE_BUILD_TYPE "Debug" CACHE STRING "Build type" FORCE) set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug" "Release" "MinSizeRel" "RelWithDebInfo") endif()