Merge branch '356-build-system-add-key-in-yaml-config-in-which-the-functions-required-to-build-a-module-variant' into 'master'

Resolve "build-system: add key in YAML config in which the functions required to build a module/variant can be set"

Closes #356

See merge request Pmodules/src!359

(cherry picked from commit b74839e1ef)

70252320 build-system: configurable build functions to use per module/variant

Co-authored-by: gsell <achim.gsell@psi.ch>
This commit is contained in:
2024-09-09 12:09:52 +02:00
parent d3162fe543
commit 5b54a5f1f8
2 changed files with 53 additions and 23 deletions
+3 -23
View File
@@ -1431,29 +1431,9 @@ _build_module() {
[[ ${force_rebuild} == 'no' ]]; then
return 0
fi
local targets=()
targets+=( "${VERSIONS[@]/#/pbuild::pre_${target}_${system}_}" )
targets+=( "pbuild::pre_${target}_${system}" )
targets+=( "${VERSIONS[@]/#/pbuild::pre_${target}_${KernelName}_}" )
targets+=( "pbuild::pre_${target}_${KernelName}" )
targets+=( "${VERSIONS[@]/#/pbuild::pre_${target}_}" )
targets+=( "pbuild::pre_${target}" )
targets+=( "${VERSIONS[@]/#/pbuild::${target}_${system}_}" )
targets+=( "pbuild::${target}_${system}" )
targets+=( "${VERSIONS[@]/#/pbuild::${target}_${KernelName}_}" )
targets+=( "pbuild::${target}_${KernelName}" )
targets+=( "${VERSIONS[@]/#/pbuild::${target}_}" )
targets+=( "pbuild::${target}" )
targets+=( "${VERSIONS[@]/#/pbuild::post_${target}_${system}_}" )
targets+=( "pbuild::post_${target}_${system}" )
targets+=( "${VERSIONS[@]/#/pbuild::post_${target}_${KernelName}_}" )
targets+=( "pbuild::post_${target}_${KernelName}" )
targets+=( "${VERSIONS[@]/#/pbuild::post_${target}_}" )
targets+=( "pbuild::post_${target}" )
for t in "${targets[@]}"; do
debug "build functions for target ${target}: ${ModuleConfig[target_funcs:${target}]}"
local -- t=''
for t in ${ModuleConfig[target_funcs:${target}]}; do
# We cd into the dir before calling the function -
# just to be sure we are in the right directory.
#