mirror of
https://github.com/godotengine/godot-cpp.git
synced 2026-01-03 18:09:13 +03:00
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:
@@ -271,9 +271,6 @@ function(godotcpp_generate)
|
||||
"${CMAKE_CURRENT_BINARY_DIR}"
|
||||
)
|
||||
|
||||
add_custom_target(godot-cpp.generate_bindings DEPENDS ${GENERATED_FILES_LIST})
|
||||
set_target_properties(godot-cpp.generate_bindings PROPERTIES FOLDER "godot-cpp")
|
||||
|
||||
### Platform is derived from the toolchain target
|
||||
# See GeneratorExpressions PLATFORM_ID and CMAKE_SYSTEM_NAME
|
||||
string(
|
||||
@@ -332,6 +329,9 @@ function(godotcpp_generate)
|
||||
# the godot-cpp.* library targets
|
||||
add_library(godot-cpp STATIC)
|
||||
|
||||
# Without adding this dependency to the binding generator, XCode will complain.
|
||||
add_dependencies(godot-cpp generate_bindings)
|
||||
|
||||
# Added for backwards compatibility with prior cmake solution so that builds dont immediately break
|
||||
# from a missing target.
|
||||
add_library(godot::cpp ALIAS godot-cpp)
|
||||
|
||||
Reference in New Issue
Block a user