Merge integration refs/builds/qtci/dev/1617109351

This commit is contained in:
Qt CI Bot 2021-03-30 16:02:41 +00:00
commit 5d5cc3c7c7
3 changed files with 21 additions and 6 deletions

View File

@ -43,6 +43,13 @@ else()
set(commandline_files "${MODULE_ROOT}/${commandline_filename}")
endif()
file(STRINGS "${OPTFILE}" configure_args)
# list(TRANSFORM ...) unexpectedly removes semicolon escaping in list items. So the list arguments
# seem to be broken. The 'bracket argument' suppresses this behavior. Right before forwarding
# command line arguments to the cmake call, 'bracket arguments' are replaced by escaped semicolons
# back.
list(TRANSFORM configure_args REPLACE ";" "[[;]]")
list(FILTER configure_args EXCLUDE REGEX "^[ \t]*$")
list(TRANSFORM configure_args STRIP)
list(TRANSFORM configure_args REPLACE "\\\\" "\\\\\\\\")
@ -82,9 +89,7 @@ while(NOT "${configure_args}" STREQUAL "")
elseif(arg MATCHES "^-host.*dir")
message(FATAL_ERROR "${arg} is not supported anymore.")
elseif(arg STREQUAL "--")
# Everything after this argument will be passed to CMake verbatim,
# but we need to escape semi-colons so that lists are preserved.
string(REPLACE ";" "\\;" configure_args "${configure_args}")
# Everything after this argument will be passed to CMake verbatim.
list(APPEND cmake_args "${configure_args}")
break()
else()
@ -821,6 +826,9 @@ endif()
push("${MODULE_ROOT}")
# Restore the escaped semicolons in arguments that are lists
list(TRANSFORM cmake_args REPLACE "\\[\\[;\\]\\]" "\\\\;")
execute_process(COMMAND "${CMAKE_COMMAND}" ${cmake_args}
COMMAND_ECHO STDOUT
RESULT_VARIABLE exit_code)

View File

@ -1185,6 +1185,9 @@ function(__qt_propagate_generated_resource target resource_name generated_source
set(resource_target "${target}_resources_${resource_count}")
add_library("${resource_target}" OBJECT "${generated_source_code}")
target_compile_definitions("${resource_target}" PRIVATE
"$<TARGET_PROPERTY:${QT_CMAKE_EXPORT_NAMESPACE}::Core,INTERFACE_COMPILE_DEFINITIONS>"
)
set_property(TARGET ${resource_target} APPEND PROPERTY _qt_resource_name ${resource_name})
# Save the path to the generated source file, relative to the the current build dir.

View File

@ -7314,8 +7314,10 @@ void tst_QObject::checkArgumentsForNarrowing()
FITS(ConvertingToDouble, long double);
// no compiler still implements this properly.
#if 0
// GCC and clang don't implement this properly yet:
// https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99625
// https://bugs.llvm.org/show_bug.cgi?id=49676
#if defined(Q_CC_MSVC) // at least since VS2017
struct ConstructibleFromInt {
/* implicit */ ConstructibleFromInt(int) {}
};
@ -7334,7 +7336,9 @@ void tst_QObject::checkArgumentsForNarrowing()
class ForwardDeclared;
FITS(ForwardDeclared, ForwardDeclared);
#if 0 // waiting for official compiler releases that implement P1957...
#if (defined(Q_CC_EXACTLY_GCC) && Q_CC_EXACTLY_GCC >= 1100) \
|| (defined(Q_CC_CLANG) && Q_CC_CLANG >= 1100) \
|| defined(Q_CC_MSVC) // at least since VS2017
{
// wg21.link/P1957
NARROWS(char*, bool);