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

[Release][CMake][Bugfix] Make dune_library_add_sources() work again

dune_library_add_sources() verifies the library name against the
contents of DUNE_ENABLE_ALL_PACKAGES_MODULE_LIBRARIES. I accidentally
broke this by converting dune_enable_all_packages (which defines the
variable) from a macro to a function, which removed the variable from
global scope.

This patch fixes the problem by explicitly exporting the variable to the
parent scope, making it available to dune_library_add_sources() again.
parent bd578fd8
No related branches found
No related tags found
No related merge requests found
......@@ -221,6 +221,14 @@ Update the cmake_minimum_required() call in your main CMakeLists.txt file to get
# ...and add it to all future targets in the module
link_libraries(${module_lib})
endforeach(module_lib ${DUNE_ENABLE_ALL_PACKAGES_MODULE_LIBRARIES})
# export the DUNE_ENABLE_ALL_PACKAGES_MODULE_LIBRARIES variable to the parent scope
# this is required to make dune_library_add_sources() work (see further down)
set(
DUNE_ENABLE_ALL_PACKAGES_MODULE_LIBRARIES
${DUNE_ENABLE_ALL_PACKAGES_MODULE_LIBRARIES}
PARENT_SCOPE
)
endif(DUNE_ENABLE_ALL_PACKAGES_MODULE_LIBRARIES)
if(DUNE_ENABLE_ALL_PACKAGES_VERBOSE)
......
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