From d7073fa29aaca5025e1d52ad62178016e9c50961 Mon Sep 17 00:00:00 2001 From: Joseph Hickey Date: Mon, 24 May 2021 16:19:06 -0400 Subject: [PATCH] HOTFIX IC 2021-05-19, table build with app name mismatch For a table build where the app name passed to cfe_add_tables does not match the actual app name, it must use the APP_DYNAMIC_TARGET_LIST and APP_STATIC_TARGET_LIST variables to get the target list for installation. --- cmake/arch_build.cmake | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/cmake/arch_build.cmake b/cmake/arch_build.cmake index e8781da79..7c2e6466e 100644 --- a/cmake/arch_build.cmake +++ b/cmake/arch_build.cmake @@ -150,19 +150,18 @@ function(add_cfe_tables APP_NAME TBL_SRC_FILES) if (TGTNAME) set (TABLE_TGTLIST ${TGTNAME}) - else() + elseif (TARGET ${APP_NAME}) set (TABLE_TGTLIST ${TGTLIST_${APP_NAME}}) - endif() - - # The first parameter should match the name of an app that was - # previously defined using "add_cfe_app". If target-scope properties - # are used for include directories and compile definitions, this is needed - # to compile tables with the same include path/definitions as the app has. - # However historically this could have been any string, which still works - # if directory-scope properties are used for includes, so this is not - # an error. - if (NOT TARGET ${APP_NAME}) + else() + # The first parameter should match the name of an app that was + # previously defined using "add_cfe_app". If target-scope properties + # are used for include directories and compile definitions, this is needed + # to compile tables with the same include path/definitions as the app has. + # However historically this could have been any string, which still works + # if directory-scope properties are used for includes, so this is not + # an error. message("NOTE: \"${APP_NAME}\" passed to add_cfe_tables is not a previously-defined application target") + set (TABLE_TGTLIST ${APP_STATIC_TARGET_LIST} ${APP_DYNAMIC_TARGET_LIST}) endif() # The table source must be compiled using the same "include_directories"