From 28d0573dfc414216d4a4c8df1f2f72313ede6222 Mon Sep 17 00:00:00 2001 From: Chris Green Date: Tue, 16 Apr 2024 10:26:18 -0500 Subject: [PATCH] Reorder relative path expansion to resolve dictionary checking issues --- Modules/BuildDictionary.cmake | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Modules/BuildDictionary.cmake b/Modules/BuildDictionary.cmake index 94004e17..ba4a8d95 100644 --- a/Modules/BuildDictionary.cmake +++ b/Modules/BuildDictionary.cmake @@ -285,6 +285,11 @@ function(build_dictionary) else() set(BD_SOURCES_H) endif() + foreach(item IN ITEMS BD_CLASSES_H BD_CLASSES_DEF_XML linkdef_h_files) + if (${item}) + cmake_path(ABSOLUTE_PATH ${item}) + endif() + endforeach() if (BD_LIB_TARGET_VAR) set(${BD_LIB_TARGET_VAR} ${BD_LIB_TARGET} PARENT_SCOPE) endif() @@ -417,11 +422,6 @@ function(_generate_dictionary) foreach(item IN LISTS BD_CLASSES_H BD_SOURCES_H) list(APPEND implicit_depends CXX ${item}) endforeach() - foreach(item IN ITEMS BD_CLASSES_H BD_CLASSES_DEF_XML linkdef_h_files) - if (${item}) - cmake_path(ABSOLUTE_PATH ${item}) - endif() - endforeach() add_custom_command( # See https://gitlab.kitware.com/cmake/cmake/-/issues/21364#note_849331 OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${BD_GENERATED_SOURCE_FILENAME} # ${AUX_OUTPUT}