Skip to content
Snippets Groups Projects
Commit 25e36cfc authored by Dominic Kempf's avatar Dominic Kempf
Browse files

Split ALL_PKG_FLAGS into ALL_PKG_DEFS and ALL_PKG_INCS

parent 9addf077
Branches
Tags
No related merge requests found
......@@ -517,10 +517,8 @@ macro(dune_process_dependency_macros)
endforeach(_lib ${${_mod}_LIBRARIES})
endif(${_mod}_LIBRARIES)
#update ALL_PKG_FLAGS
foreach(dir ${${_mod}_INCLUDE_DIRS})
set_property(GLOBAL APPEND PROPERTY ALL_PKG_FLAGS "-I${dir}")
endforeach()
#update ALL_PKG_INCS
set_property(GLOBAL APPEND PROPERTY ALL_PKG_INCS "${${_mod}_INCLUDE_DIRS}")
endif(NOT ${_mod}_PROCESSED)
endforeach(_mod DEPENDENCIES)
endmacro(dune_process_dependency_macros)
......@@ -1148,16 +1146,12 @@ and a replacement string. ${REPLACE_UNPARSED_ARGUMENTS}")
endfunction(replace_properties)
macro(add_dune_all_flags targets)
get_property(flags GLOBAL PROPERTY ALL_PKG_FLAGS)
set(FLAGSTR "")
foreach(flag ${flags})
set(FLAGSTR "${FLAGSTR}\ ${flag}")
endforeach()
get_property(incs GLOBAL PROPERTY ALL_PKG_INCS)
get_property(defs GLOBAL PROPERTY ALL_PKG_DEFS)
get_property(libs GLOBAL PROPERTY ALL_PKG_LIBS)
foreach(target ${targets})
set_property(TARGET ${target}
APPEND_STRING
PROPERTY COMPILE_FLAGS ${FLAGSTR})
get_property(libs GLOBAL PROPERTY ALL_PKG_LIBS)
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})
endforeach()
endmacro(add_dune_all_flags targets)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment