Skip to content
Snippets Groups Projects
Commit 556f4491 authored by Steffen Müthing's avatar Steffen Müthing
Browse files

[cmake] Apply compile options in add_dune_all_flags()

Package registration using dune_register_package_flags() can register compile options that need to
be enabled on a target, but add_dune_all_flags() did not apply them.

This patch fixes that omission.
parent 317d5564
No related branches found
No related tags found
No related merge requests found
......@@ -1263,9 +1263,11 @@ macro(add_dune_all_flags targets)
get_property(incs GLOBAL PROPERTY ALL_PKG_INCS)
get_property(defs GLOBAL PROPERTY ALL_PKG_DEFS)
get_property(libs GLOBAL PROPERTY ALL_PKG_LIBS)
get_property(opts GLOBAL PROPERTY ALL_PKG_OPTS)
foreach(target ${targets})
set_property(TARGET ${target} APPEND PROPERTY INCLUDE_DIRECTORIES ${incs})
set_property(TARGET ${target} APPEND PROPERTY COMPILE_DEFINITIONS ${defs})
target_link_libraries(${target} ${DUNE_LIBS} ${libs})
target_compile_options(${target} PUBLIC ${opts})
endforeach()
endmacro(add_dune_all_flags targets)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment