Skip to content

Commit

Permalink
add empty section for compile options (#1741)
Browse files Browse the repository at this point in the history
  • Loading branch information
danewalton authored May 27, 2021
1 parent e2e3cee commit 9a82293
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion eng/cmake/global_compile_options.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,12 @@ elseif(CMAKE_C_COMPILER_ID MATCHES "Clang")
endif()

add_compile_options(-Xclang -Wall -Wextra -pedantic ${WARNINGS_AS_ERRORS_FLAG} -Wdocumentation -Wdocumentation-unknown-command -fcomment-block-commands=retval -Wcast-qual -Wunused -Wuninitialized -Wmissing-declarations -Wconversion -Wpointer-arith -Wshadow -Wfloat-equal)
else()
elseif(CMAKE_C_COMPILER_ID MATCHES "GNU")
if(WARNINGS_AS_ERRORS)
set(WARNINGS_AS_ERRORS_FLAG "-Werror")
endif()

add_compile_options(-Wall -Wextra -pedantic ${WARNINGS_AS_ERRORS_FLAG} -Wcast-qual -Wunused -Wuninitialized -Wmissing-declarations -Wconversion -Wpointer-arith -Wshadow -Wlogical-op -Wfloat-equal)
else()
message(WARNING "Using an unsupported compiler. Disabling stricter compiler flags.")
endif()

0 comments on commit 9a82293

Please sign in to comment.