CMake: XCode dependency chain fixes - remastered

When attempting to generate XCode projects it would fail due to the target dependency chain not meeting expectations.

This PR, adds the required dependency infomation so that the XCode generator works.
This commit is contained in:
Samuel Nicholas
2025-03-11 12:33:38 +10:30
parent 6f981b33cc
commit f83f364144
3 changed files with 12 additions and 21 deletions

View File

@@ -7,13 +7,6 @@ The Test target used to validate changes in the GitHub CI.
message(STATUS "Testing Integration targets are enabled.")
# Generate Doc Data
file(GLOB_RECURSE DOC_XML LIST_DIRECTORIES NO CONFIGURE_DEPENDS "${CMAKE_CURRENT_SOURCE_DIR}/doc_classes/*.xml")
set(DOC_SOURCE_FILE "${CMAKE_CURRENT_BINARY_DIR}/gen/doc_source.cpp")
generate_doc_source( "${DOC_SOURCE_FILE}" ${DOC_XML} )
set(TARGET_NAME "godot-cpp-test")
add_library(${TARGET_NAME} SHARED EXCLUDE_FROM_ALL)
@@ -25,7 +18,8 @@ target_sources(
# conditionally add doc data to compile output
if(GODOTCPP_TARGET MATCHES "editor|template_debug")
target_sources(${TARGET_NAME} PRIVATE "${DOC_SOURCE_FILE}")
file(GLOB_RECURSE DOC_XML LIST_DIRECTORIES NO CONFIGURE_DEPENDS "${CMAKE_CURRENT_SOURCE_DIR}/doc_classes/*.xml")
target_doc_sources( ${TARGET_NAME} ${DOC_XML} )
endif()
set(OUTPUT_DIR "${CMAKE_CURRENT_SOURCE_DIR}/project/bin/")