Skip to content

Commit 94be052

Browse files
committed
Output EXTRA_DEBUG_OUTPUT when debug builds are selected
1 parent 840374a commit 94be052

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

CMakeLists.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,10 @@ the C compiler if it matches the Fortran compiler ID." )
158158
set( CMAKE_Fortran_COMPILER_VERSION "${DETECTED_VER}" )
159159
endif()
160160

161+
if(CMAKE_BUILD_TYPE MATCHES "Debug|DEBUG|debug")
162+
add_definitions(-DEXTRA_DEBUG_OUTPUT)
163+
endif()
164+
161165
# We have populated CMAKE_Fortran_COMPILER_VERSION if it was missing
162166
if(gfortran_compiler AND (CMAKE_Fortran_COMPILER_VERSION VERSION_GREATER 5.0.0))
163167
set(opencoarrays_aware_compiler true)

0 commit comments

Comments
 (0)