Skip to content

Commit

Permalink
Enable warnings as errors in compiler component on OSX
Browse files Browse the repository at this point in the history
The commits have addressed all warnings on an OSX build, so to prevent
new warnings from being introduced we enable warnings as errors only on
this platform. Future platforms will follow.
  • Loading branch information
fjeremic committed May 6, 2021
1 parent 4ba2ff8 commit 36f9278
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions cmake/modules/OmrCompilerSupport.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -283,8 +283,14 @@ function(create_omr_compiler_library)
omr_inject_object_modification_targets(COMPILER_OBJECTS ${COMPILER_NAME} ${COMPILER_OBJECTS})

# warnings as errors and enhanced warnings currently don't work
set(OMR_WARNINGS_AS_ERRORS OFF)
set(OMR_ENHANCED_WARNINGS OFF)
if(OMR_OS_OSX AND OMR_ARCH_X86)
set(OMR_WARNINGS_AS_ERRORS ON)
set(OMR_ENHANCED_WARNINGS OFF)
else()
set(OMR_WARNINGS_AS_ERRORS OFF)
set(OMR_ENHANCED_WARNINGS OFF)
endif()

set(output_name_args "")
if(COMPILER_OUTPUT_NAME)
set(output_name_args "OUTPUT_NAME" "${COMPILER_OUTPUT_NAME}")
Expand Down

0 comments on commit 36f9278

Please sign in to comment.