Skip to content

Commit

Permalink
Update Key4hepConfig.cmake with fixes from key4hep/key4hep-dev-utils#7
Browse files Browse the repository at this point in the history
  • Loading branch information
jmcarcell committed Sep 9, 2024
1 parent 030db02 commit f6218eb
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions cmake/Key4hepConfig.cmake
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# Do not edit this file, it will be overwritten!
# The template file can be found in
# https://github.com/key4hep/key4hep-dev-utils/blob/main/defaults/cmake/Key4hepConfig.cmake

macro(key4hep_set_compiler_flags)
if (DEFINED KEY4HEP_SET_COMPILER_FLAGS AND NOT KEY4HEP_SET_COMPILER_FLAGS)
return()
endif()

set(COMPILER_FLAGS "-fPIC -Wall -Wextra -Wpedantic -Wshadow -Wdeprecated")

Expand All @@ -11,7 +12,10 @@ macro(key4hep_set_compiler_flags)
set(COMPILER_FLAGS "${COMPILER_FLAGS} -fdiagnostics-color=always")
endif()

set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${COMPILER_FLAGS}")
if (DEFINED KEY4HEP_SET_COMPILER_FLAGS AND NOT KEY4HEP_SET_COMPILER_FLAGS)
else()
set(CMAKE_CXX_FLAGS "${COMPILER_FLAGS} ${CMAKE_CXX_FLAGS}")
endif()

endmacro()

Expand Down

0 comments on commit f6218eb

Please sign in to comment.