CMake: Target as configuration option

Add GODOTCPP_TARGET configuration option
Remove loop to generate the godot-cpp.<target> CMake Targets

Rename test bindings target
Update documentation
This commit is contained in:
Samuel Nicholas
2025-03-09 12:31:56 +10:30
parent a3f89217df
commit 89abe15268
11 changed files with 239 additions and 269 deletions

View File

@@ -16,10 +16,10 @@ endfunction()
#[===========================[ Target Generation ]===========================]
function(web_generate)
target_compile_definitions(${TARGET_NAME} PUBLIC WEB_ENABLED UNIX_ENABLED)
target_compile_definitions(godot-cpp PUBLIC WEB_ENABLED UNIX_ENABLED)
target_compile_options(
${TARGET_NAME}
godot-cpp
PUBLIC #
-sSIDE_MODULE
-sSUPPORT_LONGJMP=wasm
@@ -28,7 +28,7 @@ function(web_generate)
)
target_link_options(
${TARGET_NAME}
godot-cpp
INTERFACE #
-sWASM_BIGINT
-sSUPPORT_LONGJMP=wasm