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

[cmake] Retrigger code generation from downstream modules

So far, changes in the form compiler did not trigger code regeneration
if invoked from a downstream dune module. This is fixed now.
parent 7c7045aa
No related branches found
No related tags found
No related merge requests found
......@@ -64,8 +64,14 @@ add_custom_target(generation)
if(CMAKE_PROJECT_NAME STREQUAL dune-perftool)
set(UFL2PDELAB_GLOB_PATTERN "${CMAKE_SOURCE_DIR}/python/*.py")
else()
# TODO: How do we get to the source here???
message(WARNING "You are using dune-perftool from a downstream module. This may cause insufficient retriggers of code generation")
dune_module_path(MODULE dune-perftool
RESULT perftool_path
CMAKE_MODULES)
dune_execute_process(COMMAND ${CMAKE_BINARY_DIR}/run-in-dune-env python ${perftool_path}/perftool_sourcepath.py
OUTPUT_VARIABLE perftool_source
OUTPUT_STRIP_TRAILING_WHITESPACE
)
set(UFL2PDELAB_GLOB_PATTERN "${perftool_source}/*.py")
endif()
file(GLOB_RECURSE UFL2PDELAB_SOURCES ${UFL2PDELAB_GLOB_PATTERN})
......
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