From 59fbaceae96c1b72bb952d1e5446473917b7c749 Mon Sep 17 00:00:00 2001 From: Alexandru Croitor Date: Wed, 14 Sep 2022 11:10:51 +0200 Subject: CMake: Use new _qt_internal_get_tool_wrapper_script_path MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I3c8422f4568fc60cf6cd3c247e008cacdcb18249 Reviewed-by: Qt CI Bot Reviewed-by: Jörg Bornemann (cherry picked from commit b56f34ca6c24e440174c3c249594914cb470731b) Reviewed-by: Qt Cherry-pick Bot --- src/scxml/Qt6ScxmlMacros.cmake | 7 ++++--- tests/auto/scion/CMakeLists.txt | 7 ++++--- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/src/scxml/Qt6ScxmlMacros.cmake b/src/scxml/Qt6ScxmlMacros.cmake index 066bade..ffaccaf 100644 --- a/src/scxml/Qt6ScxmlMacros.cmake +++ b/src/scxml/Qt6ScxmlMacros.cmake @@ -38,8 +38,8 @@ function(qt6_add_statecharts target_or_outfiles) endif() endif() - _qt_internal_wrap_tool_command(qscxmlc_command SET - "$") + _qt_internal_get_tool_wrapper_script_path(tool_wrapper) + set(qscxmlc_bin "${tool_wrapper}" "$") set(outfiles) foreach(it ${scxml_files}) @@ -50,7 +50,8 @@ function(qt6_add_statecharts target_or_outfiles) set(outfile_h ${qscxmlcOutputDir}/${outfilename}.h) add_custom_command(OUTPUT ${outfile_cpp} ${outfile_h} - ${qscxmlc_command} ${namespace} ${ARGS_OPTIONS} + COMMAND + ${qscxmlc_bin} ${namespace} ${ARGS_OPTIONS} --output ${outfile} ${infile} DEPENDS ${QT_CMAKE_EXPORT_NAMESPACE}::qscxmlc MAIN_DEPENDENCY ${infile} diff --git a/tests/auto/scion/CMakeLists.txt b/tests/auto/scion/CMakeLists.txt index 9f7020a..9dd6db2 100644 --- a/tests/auto/scion/CMakeLists.txt +++ b/tests/auto/scion/CMakeLists.txt @@ -79,8 +79,8 @@ set(scxmls_dir ../../3rdparty/scion-tests/scxml-test-framework/test) get_filename_component(scxmls_dir ${scxmls_dir} ABSOLUTE) file(GLOB_RECURSE allscxmls ${scxmls_dir}/*.scxml) -_qt_internal_wrap_tool_command(qscxmlc_command SET - "$") +_qt_internal_get_tool_wrapper_script_path(tool_wrapper) +set(qscxmlc_bin "${tool_wrapper}" "$") set(scxmls) set(inc_list) @@ -111,7 +111,8 @@ foreach(f ${allscxmls}) file(TO_NATIVE_PATH ${out_cpp} native_out_cpp) add_custom_command( OUTPUT ${out_cpp} ${out_h} - ${qscxmlc_command} --header ${native_out_h} --impl ${native_out_cpp} + COMMAND + ${qscxmlc_bin} --header ${native_out_h} --impl ${native_out_cpp} --namespace ${sn} --classname ${cn} ${f} DEPENDS ${QT_CMAKE_EXPORT_NAMESPACE}::qscxmlc VERBATIM -- cgit v1.2.3