wasm: fix setting RUNTIME_OUTPUT_DIRECTORY

match does not work, as cmake uses a string for NOTFOUND

Change-Id: I160a1f7ed69592b85fcbf0d8b5773713121ee9a4
Reviewed-by: David Skoland <david.skoland@qt.io>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
This commit is contained in:
Lorn Potter 2022-09-07 18:42:27 +10:00
parent fe486d0fb4
commit 497cd38c1a

View File

@ -15,7 +15,7 @@ function(_qt_internal_wasm_add_target_helpers target)
endif() endif()
get_target_property(output_name ${target} OUTPUT_NAME) get_target_property(output_name ${target} OUTPUT_NAME)
if(NOT "${output_name}" STREQUAL "") if(output_name)
set(_target_output_name "${output_name}") set(_target_output_name "${output_name}")
else() else()
set(_target_output_name "${target}") set(_target_output_name "${target}")
@ -36,7 +36,7 @@ function(_qt_internal_wasm_add_target_helpers target)
configure_file("${WASM_BUILD_DIR}/libexec/util.js" configure_file("${WASM_BUILD_DIR}/libexec/util.js"
"${target_output_directory}/util.js" COPYONLY) "${target_output_directory}/util.js" COPYONLY)
else() else()
if(NOT "${target_output_directory}" STREQUAL "") if(target_output_directory)
set(_target_directory "${target_output_directory}") set(_target_directory "${target_output_directory}")
else() else()
set(_target_directory "${CMAKE_CURRENT_BINARY_DIR}") set(_target_directory "${CMAKE_CURRENT_BINARY_DIR}")