Explorar o código

Merge topic 'ci-macos-qt-6.9.3'

3f21bf9f0a ci: Restore packaging with macOS SDK from Xcode
c1ee4d57dc Utilities/Release: Remove unused Qt 5.15.2 build script for macOS
0f18aa010e ci: Update to Qt 6.9.3 on macOS
2ae318bb5d cmake-gui: Install only necessary plugins for Qt 6
74dec2c7fd cmake-gui: Detect Qt lib directory on macOS more robustly
0d1321770d cmake-gui: Clarify signature of QCheckBox::checkStateChanged callbacks
a49e5c8eb9 Utilities/Release: Teach macOS notarization script to sign Qt artifacts

Acked-by: Kitware Robot <[email protected]>
Merge-request: !11386
Brad King hai 2 meses
pai
achega
7bcdf7353a

+ 1 - 1
.gitlab/.gitignore

@@ -1,5 +1,6 @@
 # Ignore files known to be downloaded by CI jobs.
 /5.15.1-0-202009071110*
+/6.9.3-0-202509261207*
 /appimagetool
 /bcc*
 /cmake*
@@ -11,7 +12,6 @@
 /innosetup
 /jom
 /llvm*
-/MacOS*
 /mingw
 /msvc*
 /ninja*

+ 1 - 0
.gitlab/ci/configure_macos_package.cmake

@@ -1,5 +1,6 @@
 set(CPACK_SYSTEM_NAME "macos-universal" CACHE STRING "")
 set(CMAKE_OSX_DEPLOYMENT_TARGET "10.13" CACHE STRING "")
+set(CMake_GUI_OSX_DEPLOYMENT_TARGET "12" CACHE STRING "")
 set(CMAKE_C_STANDARD "11" CACHE STRING "")
 set(CMAKE_CXX_STANDARD "17" CACHE STRING "")
 

+ 0 - 1
.gitlab/ci/configure_macos_package_common.cmake

@@ -11,7 +11,6 @@ set(BUILD_CursesDialog "ON" CACHE BOOL "")
 set(BUILD_QtDialog "TRUE" CACHE BOOL "")
 set(CMake_GUI_DISTRIBUTE_WITH_Qt_LGPL "3" CACHE STRING "")
 set(CMake_INSTALL_DEPENDENCIES "ON" CACHE BOOL "")
-set(CMAKE_SKIP_RPATH "TRUE" CACHE BOOL "")
 set(CMake_TEST_BOOTSTRAP OFF CACHE BOOL "")
 set(CMake_TEST_NO_FindPackageModeMakefileTest "TRUE" CACHE BOOL "")
 

+ 7 - 0
.gitlab/ci/ctest_exclusions.cmake

@@ -41,6 +41,13 @@ if ("$ENV{CMAKE_CONFIGURATION}" MATCHES "_valgrind")
     )
 endif()
 
+if ("$ENV{CMAKE_CONFIGURATION}" MATCHES "_xcode")
+  list(APPEND test_exclusions
+    # FIXME(#27358): Qt6Autogen.RerunMocOnAddFile fails in Xcode.
+    "^Qt6Autogen.RerunMocOnAddFile$"
+    )
+endif()
+
 string(REPLACE ";" "|" test_exclusions "${test_exclusions}")
 if (test_exclusions)
   set(test_exclusions "(${test_exclusions})")

+ 14 - 6
.gitlab/ci/download_qt.cmake

@@ -9,6 +9,8 @@ set(qt_version_patch "1")
 set(qt_version "${qt_version_major}.${qt_version_minor}.${qt_version_patch}")
 set(qt_version_nodot "${qt_version_major}${qt_version_minor}${qt_version_patch}")
 
+set(qt_tar_workdir ".gitlab")
+
 # Files needed to download.
 set(qt_files)
 if ("$ENV{CMAKE_CONFIGURATION}" MATCHES "windows.*package")
@@ -61,14 +63,19 @@ elseif ("$ENV{CMAKE_CONFIGURATION}" MATCHES "windows")
   set(qt_url_path "${qt_platform}/desktop/qt5_${qt_version_nodot}/qt.qt5.${qt_version_nodot}.${qt_abi}")
 elseif ("$ENV{CMAKE_CONFIGURATION}" MATCHES "macos")
   if ("$ENV{CMAKE_CONFIGURATION}" MATCHES "macos10.10_package")
+    set(qt_url_root "https://cmake.org/files/dependencies")
+    set(qt_url_path "")
     list(APPEND qt_files "qt-5.9.9-macosx10.10-x86_64-arm64.tar.xz")
     set(qt_subdir "qt-5.9.9-macosx10.10-x86_64-arm64")
   else ()
-    list(APPEND qt_files "qt-5.15.2-macosx10.13-x86_64-arm64.tar.xz")
-    set(qt_subdir "qt-5.15.2-macosx10.13-x86_64-arm64")
+    # This URL is only visible inside of Kitware's network.
+    # Please use your own Qt Account to obtain these files.
+    set(qt_url_root "https://www.paraview.org/files/dependencies/internal/qt")
+    set(qt_url_path "mac_x64/desktop/qt6_693/qt6_693/qt.qt6.693.clang_64")
+    list(APPEND qt_files "6.9.3-0-202509261207qtbase-MacOS-MacOS_15-Clang-MacOS-MacOS_15-X86_64-ARM64.7z")
+    set(qt_subdir "qt-extract")
+    set(qt_tar_workdir ".gitlab/${qt_subdir}")
   endif()
-  set(qt_url_root "https://cmake.org/files/dependencies")
-  set(qt_url_path "")
 else()
   message(FATAL_ERROR "Unknown OS to use for Qt")
 endif ()
@@ -109,12 +116,13 @@ foreach (qt_file IN LISTS qt_files)
   endif ()
 
   # Extract the file.
+  file(MAKE_DIRECTORY "${qt_tar_workdir}")
   execute_process(
     COMMAND
       "${CMAKE_COMMAND}"
       -E tar
-      xf "${qt_file}"
-    WORKING_DIRECTORY ".gitlab"
+      xf "${CMAKE_CURRENT_SOURCE_DIR}/.gitlab/${qt_file}"
+    WORKING_DIRECTORY "${qt_tar_workdir}"
     RESULT_VARIABLE res
     ERROR_VARIABLE err
     ERROR_STRIP_TRAILING_WHITESPACE)

+ 1 - 1
.gitlab/ci/download_qt_hashes.cmake

@@ -11,7 +11,7 @@ set("5.15.1-0-202009071110qtwinextras-Windows-Windows_10-MSVC2015-Windows-Window
 set("5.15.1-0-202009071110qtbase-MacOS-MacOS_10_13-Clang-MacOS-MacOS_10_13-X86_64.7z_hash" df2813ce7c6cb4287abd7956cd1cb9d08312e4ac1208b6cb57af4df11b8ebba1)
 
 set("qt-5.9.9-macosx10.10-x86_64-arm64.tar.xz_hash" d4449771afa0bc6a809c14f1e6d939e7732494cf059503ae451e2bfe8fc60cc1)
-set("qt-5.15.2-macosx10.13-x86_64-arm64.tar.xz_hash" 7b9463a01c8beeee5bf8d01c70deff2d08561cd20aaf6f7a2f41cf8b68ce8a6b)
+set("6.9.3-0-202509261207qtbase-MacOS-MacOS_15-Clang-MacOS-MacOS_15-X86_64-ARM64.7z_hash" 805144e619b7c7b0e9c985d929e1f290241d88b884218db3ad7d56bd579d6b4a)
 
 set("qt-5.15.10-win-i386-msvc_v142-1.zip_hash" c158cebc054d3f4f09733772a8a04789e2884912d45782e8c0c5e6a0b2773e92)
 set("qt-5.15.10-win-x86_64-msvc_v142-1.zip_hash" d55c017aef359f6aa8c592b18ba13cc120c749417b55671548970690126cd139)

+ 0 - 1
.gitlab/ci/env_macos_package.sh

@@ -1 +0,0 @@
-. .gitlab/ci/macos-env.sh

+ 0 - 2
.gitlab/ci/macos-env.sh

@@ -1,2 +0,0 @@
-.gitlab/ci/macos.sh
-export SDKROOT="$PWD/.gitlab/MacOSX.sdk"

+ 0 - 28
.gitlab/ci/macos.sh

@@ -1,28 +0,0 @@
-#!/bin/sh
-
-set -e
-
-# This URL is only visible inside of Kitware's network.
-baseurl="https://cmake.org/files/dependencies/internal/macos"
-
-case "$(uname -s)-$(uname -m)" in
-    Darwin-*)
-        shatool="shasum -a 256"
-        sha256sum="427612880d6c40bcef2b0ecb39d92b057ee7a43ec3552fbd4449859991eb1cc6"
-        tarball="MacOSX15.5.sdk.tar.bz2"
-        ;;
-    *)
-        echo "Unrecognized platform $(uname -s)-$(uname -m)"
-        exit 1
-        ;;
-esac
-readonly shatool
-readonly sha256sum
-
-cd .gitlab
-
-echo "$sha256sum  $tarball" > macos.sha256sum
-curl -OL "$baseurl/$tarball"
-$shatool --check macos.sha256sum
-tar xjf "$tarball"
-rm "$tarball" macos.sha256sum

+ 0 - 8
.gitlab/ci/repackage/macos.sh

@@ -1,8 +0,0 @@
-#!/usr/bin/env bash
-
-set -e
-
-sdkPath="$(xcrun --show-sdk-path)"
-sdkVers="$(xcrun --show-sdk-version)"
-
-tar cjf "MacOSX${sdkVers}.sdk.tar.bz2" -C "${sdkPath%/*}" --no-fflags "MacOSX.sdk"

+ 6 - 0
Help/release/dev/ci-macos-qt.rst

@@ -0,0 +1,6 @@
+ci-macos-qt
+-----------
+
+* The precompiled macOS binary provided on ``cmake.org`` for macOS 10.13+
+  now requires macOS 12 or newer for the :manual:`cmake-gui(1)` application.
+  The command-line tools still run on macOS 10.13.

+ 43 - 47
Source/QtDialog/CMakeLists.txt

@@ -1,6 +1,10 @@
 # Distributed under the OSI-approved BSD 3-Clause License.  See accompanying
 # file LICENSE.rst or https://cmake.org/licensing for details.
 
+if(CMake_GUI_OSX_DEPLOYMENT_TARGET)
+  set(CMAKE_OSX_DEPLOYMENT_TARGET "${CMake_GUI_OSX_DEPLOYMENT_TARGET}")
+endif()
+
 project(QtDialog)
 CMake_OPTIONAL_COMPONENT(cmake-gui)
 set(QT_COMPONENTS
@@ -69,7 +73,7 @@ if(CMake_QT_STATIC_QWindowsIntegrationPlugin_LIBRARIES)
 endif()
 
 # We need to install platform plugin and add qt.conf for Qt5 on Mac and Windows.
-if(CMake_INSTALL_DEPENDENCIES AND (APPLE OR WIN32))
+if(CMake_INSTALL_DEPENDENCIES AND (APPLE OR WIN32) AND NOT COMMAND qt_generate_deploy_app_script)
   function(_qt_get_plugin_name_with_version target out_var)
       string(REGEX REPLACE "^Qt::(.+)" "Qt${CMake_QT_MAJOR_VERSION}::\\1"
              qt_plugin_with_version "${target}")
@@ -105,32 +109,15 @@ if(CMake_INSTALL_DEPENDENCIES AND (APPLE OR WIN32))
         "${${_qt_plugins_var}};\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/${_qt_plugin_dest}/${_qt_plugin_file}")
     endif()
   endmacro()
-  macro(install_qt_plugins _comps _plugins_var)
-    foreach(_qt_comp IN LISTS ${_comps})
-      if(CMake_QT_MAJOR_VERSION VERSION_LESS 6)
-        set(_qt_module_plugins ${Qt${CMake_QT_MAJOR_VERSION}${_qt_comp}_PLUGINS})
-      else()
-        get_target_property(_qt_module_plugins Qt${CMake_QT_MAJOR_VERSION}::${_qt_comp} QT_PLUGINS)
-      endif()
-      foreach(_qt_plugin IN LISTS _qt_module_plugins)
-        if(CMake_QT_MAJOR_VERSION VERSION_GREATER_EQUAL 6)
-          # Qt6 provides the plugins as individual packages that need to be found.
-          find_package(Qt${CMake_QT_MAJOR_VERSION}${_qt_plugin} QUIET
-            PATHS ${Qt${CMake_QT_MAJOR_VERSION}${_qt_comp}_DIR})
-        endif()
-        install_qt_plugin("${_qt_plugin}" "${_plugins_var}")
-      endforeach()
-    endforeach()
-  endmacro()
   if(APPLE)
-    if(CMake_QT_MAJOR_VERSION VERSION_EQUAL 5)
-      install_qt_plugin("Qt5::QCocoaIntegrationPlugin" QT_PLUGINS)
-      if(TARGET Qt5::QMacStylePlugin)
-        install_qt_plugin("Qt5::QMacStylePlugin" QT_PLUGINS)
-      endif()
-    else()
-      # FIXME: Minimize plugins for Qt6.
-      install_qt_plugins(QT_COMPONENTS QT_PLUGINS)
+    if(CMake_QT_MAJOR_VERSION VERSION_GREATER_EQUAL 6)
+      # Qt6 provides the plugins as individual packages that need to be found.
+      find_package(Qt${CMake_QT_MAJOR_VERSION}QCocoaIntegrationPlugin QUIET PATHS ${Qt${CMake_QT_MAJOR_VERSION}Gui_DIR})
+      find_package(Qt${CMake_QT_MAJOR_VERSION}QMacStylePlugin QUIET PATHS ${Qt${CMake_QT_MAJOR_VERSION}Widgets_DIR})
+    endif()
+    install_qt_plugin("Qt${CMake_QT_MAJOR_VERSION}::QCocoaIntegrationPlugin" QT_PLUGINS)
+    if(TARGET Qt${CMake_QT_MAJOR_VERSION}::QMacStylePlugin)
+      install_qt_plugin("Qt${CMake_QT_MAJOR_VERSION}::QMacStylePlugin" QT_PLUGINS)
     endif()
     file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/qt.conf"
       "[Paths]\nPlugins = ${_qt_plugin_dir}\n")
@@ -138,12 +125,11 @@ if(CMake_INSTALL_DEPENDENCIES AND (APPLE OR WIN32))
       DESTINATION "${CMake_INSTALL_APP_DIR_SLASH}Resources"
       ${COMPONENT})
   elseif(WIN32 AND NOT CMake_QT_STATIC_QWindowsIntegrationPlugin_LIBRARIES)
-    if(CMake_QT_MAJOR_VERSION VERSION_EQUAL 5)
-      install_qt_plugin("Qt5::QWindowsIntegrationPlugin" QT_PLUGINS)
-    else()
-      # FIXME: Minimize plugins for Qt6.
-      install_qt_plugins(QT_COMPONENTS QT_PLUGINS)
+    if(CMake_QT_MAJOR_VERSION VERSION_GREATER_EQUAL 6)
+      # Qt6 provides the plugins as individual packages that need to be found.
+      find_package(Qt${CMake_QT_MAJOR_VERSION}QWindowsIntegrationPlugin QUIET PATHS ${Qt${CMake_QT_MAJOR_VERSION}Gui_DIR})
     endif()
+    install_qt_plugin("Qt${CMake_QT_MAJOR_VERSION}::QWindowsIntegrationPlugin" QT_PLUGINS)
     file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/qt.conf"
       "[Paths]\nPlugins = ../${_qt_plugin_dir}\n")
     install(FILES "${CMAKE_CURRENT_BINARY_DIR}/qt.conf"
@@ -152,12 +138,6 @@ if(CMake_INSTALL_DEPENDENCIES AND (APPLE OR WIN32))
   endif()
 endif()
 
-get_property(_Qt_Core_LOCATION TARGET Qt${CMake_QT_MAJOR_VERSION}::Core PROPERTY LOCATION)
-get_filename_component(Qt_BIN_DIR "${_Qt_Core_LOCATION}" PATH)
-if(APPLE)
-  get_filename_component(Qt_BIN_DIR "${Qt_BIN_DIR}" PATH)
-endif()
-
 set(CMAKE_INCLUDE_CURRENT_DIR ON)
 
 add_library(
@@ -356,17 +336,33 @@ if(APPLE)
 endif()
 
 if(CMake_INSTALL_DEPENDENCIES AND (APPLE OR WIN32))
-  # install rules for including 3rd party libs such as Qt
-  # if a system Qt is used (e.g. installed in /usr/lib/), it will not be included in the installation
-  set(fixup_exe "\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/${CMake_INSTALL_BIN_DIR}/cmake-gui${CMAKE_EXECUTABLE_SUFFIX}")
-  if(APPLE)
-    set(fixup_exe "\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/${CMake_INSTALL_APP_DIR_SLASH}MacOS/CMake")
+  if(COMMAND qt_generate_deploy_app_script)
+    # Qt libraries are found via @rpath, so point the runtime path at them.
+    set_property(TARGET cmake-gui PROPERTY INSTALL_RPATH "@executable_path/../Frameworks")
+    qt_generate_deploy_app_script(
+      TARGET cmake-gui
+      OUTPUT_SCRIPT qt_deploy_script
+    )
+    install(SCRIPT "${qt_deploy_script}")
+  else()
+    # install rules for including 3rd party libs such as Qt
+    # if a system Qt is used (e.g. installed in /usr/lib/), it will not be included in the installation
+    set(fixup_exe "\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/${CMake_INSTALL_BIN_DIR}/cmake-gui${CMAKE_EXECUTABLE_SUFFIX}")
+    if(APPLE)
+      set(fixup_exe "\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/${CMake_INSTALL_APP_DIR_SLASH}MacOS/CMake")
+    endif()
+    get_property(_Qt_Core_LOCATION TARGET Qt${CMake_QT_MAJOR_VERSION}::Core PROPERTY LOCATION)
+    if(APPLE AND _Qt_Core_LOCATION MATCHES [[^(.*)/[^/]*\.framework/]])
+      set(Qt_LIB_DIR "${CMAKE_MATCH_1}")
+    else()
+      get_filename_component(Qt_LIB_DIR "${_Qt_Core_LOCATION}" PATH)
+    endif()
+    install(CODE "
+      include(BundleUtilities)
+      set(BU_CHMOD_BUNDLE_ITEMS ON)
+      fixup_bundle(\"${fixup_exe}\" \"${QT_PLUGINS}\" \"${Qt_LIB_DIR};${QT_LIBRARY_DIR};${QT_BINARY_DIR}\")
+    " ${COMPONENT})
   endif()
-  install(CODE "
-    include(BundleUtilities)
-    set(BU_CHMOD_BUNDLE_ITEMS ON)
-    fixup_bundle(\"${fixup_exe}\" \"${QT_PLUGINS}\" \"${Qt_BIN_DIR};${QT_LIBRARY_DIR};${QT_BINARY_DIR}\")
-  " ${COMPONENT})
 endif()
 
 set(CMAKE_PACKAGE_QTGUI TRUE)

+ 9 - 5
Source/QtDialog/WarningMessagesDialog.cxx

@@ -26,7 +26,7 @@ void WarningMessagesDialog::setInitialValues()
 
 void WarningMessagesDialog::setupSignals()
 {
-#if (QT_VERSION >= QT_VERSION_CHECK(6, 7, 0))
+#if QT_VERSION >= QT_VERSION_CHECK(6, 7, 0)
   static auto const checkStateChanged = &QCheckBox::checkStateChanged;
 #else
   static auto const checkStateChanged = &QCheckBox::stateChanged;
@@ -59,7 +59,8 @@ void WarningMessagesDialog::doAccept()
     this->deprecatedWarningsAsErrors->isChecked());
 }
 
-void WarningMessagesDialog::doSuppressDeveloperWarningsChanged(int state)
+void WarningMessagesDialog::doSuppressDeveloperWarningsChanged(
+  CheckState state)
 {
   // no warnings implies no errors either
   if (state) {
@@ -67,7 +68,8 @@ void WarningMessagesDialog::doSuppressDeveloperWarningsChanged(int state)
   }
 }
 
-void WarningMessagesDialog::doSuppressDeprecatedWarningsChanged(int state)
+void WarningMessagesDialog::doSuppressDeprecatedWarningsChanged(
+  CheckState state)
 {
   // no warnings implies no errors either
   if (state) {
@@ -75,7 +77,8 @@ void WarningMessagesDialog::doSuppressDeprecatedWarningsChanged(int state)
   }
 }
 
-void WarningMessagesDialog::doDeveloperWarningsAsErrorsChanged(int state)
+void WarningMessagesDialog::doDeveloperWarningsAsErrorsChanged(
+  CheckState state)
 {
   // warnings as errors implies warnings are not suppressed
   if (state) {
@@ -83,7 +86,8 @@ void WarningMessagesDialog::doDeveloperWarningsAsErrorsChanged(int state)
   }
 }
 
-void WarningMessagesDialog::doDeprecatedWarningsAsErrorsChanged(int state)
+void WarningMessagesDialog::doDeprecatedWarningsAsErrorsChanged(
+  CheckState state)
 {
   // warnings as errors implies warnings are not suppressed
   if (state) {

+ 10 - 4
Source/QtDialog/WarningMessagesDialog.h

@@ -17,6 +17,12 @@ class WarningMessagesDialog
 {
   Q_OBJECT
 
+#if QT_VERSION >= QT_VERSION_CHECK(6, 7, 0)
+  using CheckState = Qt::CheckState;
+#else
+  using CheckState = int;
+#endif
+
 public:
   WarningMessagesDialog(QWidget* prnt, QCMake* instance);
 
@@ -30,23 +36,23 @@ private slots:
    * Handler for checked state changed event of the suppress developer warnings
    * checkbox.
    */
-  void doSuppressDeveloperWarningsChanged(int state);
+  void doSuppressDeveloperWarningsChanged(CheckState state);
   /**
    * Handler for checked state changed event of the suppress deprecated
    * warnings checkbox.
    */
-  void doSuppressDeprecatedWarningsChanged(int state);
+  void doSuppressDeprecatedWarningsChanged(CheckState state);
 
   /**
    * Handler for checked state changed event of the developer warnings as
    * errors checkbox.
    */
-  void doDeveloperWarningsAsErrorsChanged(int state);
+  void doDeveloperWarningsAsErrorsChanged(CheckState state);
   /**
    * Handler for checked state changed event of the deprecated warnings as
    * errors checkbox.
    */
-  void doDeprecatedWarningsAsErrorsChanged(int state);
+  void doDeprecatedWarningsAsErrorsChanged(CheckState state);
 
 private:
   QCMake* cmakeInstance;

+ 0 - 125
Utilities/Release/macos/qt-5.15.2-macosx10.13-x86_64-arm64.bash

@@ -1,125 +0,0 @@
-#!/usr/bin/env bash
-
-# Run this script on a macOS x86_64 host to generate Qt universal binaries.
-#
-# This script requires the 'makeuniversal' tool from:
-#
-#   https://github.com/fizzyade/makeuniversal
-#
-# Build it with an existing local Qt installation first.
-#
-# Set the PATH environment variable to contain the location of 'makeuniversal'.
-
-set -e
-set -x
-
-umask 022
-
-# Verify that 'makeuniversal' is available in the PATH.
-type -p makeuniversal >/dev/null
-
-# Download, verify, and extract sources.
-curl -OL https://download.qt.io/archive/qt/5.15/5.15.2/single/qt-everywhere-src-5.15.2.tar.xz
-shasum -a 256 qt-everywhere-src-5.15.2.tar.xz | grep -q 3a530d1b243b5dec00bc54937455471aaa3e56849d2593edb8ded07228202240
-tar xjf qt-everywhere-src-5.15.2.tar.xz
-
-# Build the x86_64 variant.
-mkdir qt-5.15.2-x86_64
-cd qt-5.15.2-x86_64
-../qt-everywhere-src-5.15.2/configure \
-  --prefix=/ \
-  -platform macx-clang \
-  -device-option QMAKE_APPLE_DEVICE_ARCHS=x86_64 \
-  -device-option QMAKE_MACOSX_DEPLOYMENT_TARGET=10.13 \
-  -release \
-  -opensource -confirm-license \
-  -gui \
-  -widgets \
-  -no-gif \
-  -no-icu \
-  -no-pch \
-  -no-angle \
-  -no-opengl \
-  -no-dbus \
-  -no-harfbuzz \
-  -skip declarative \
-  -skip multimedia \
-  -skip qtcanvas3d \
-  -skip qtcharts \
-  -skip qtconnectivity \
-  -skip qtdeclarative \
-  -skip qtgamepad \
-  -skip qtlocation \
-  -skip qtmultimedia \
-  -skip qtnetworkauth \
-  -skip qtpurchasing \
-  -skip qtremoteobjects \
-  -skip qtscript \
-  -skip qtsensors \
-  -skip qtserialbus \
-  -skip qtserialport \
-  -skip qtsvg \
-  -skip qtwebchannel \
-  -skip qtwebengine \
-  -skip qtwebsockets \
-  -skip qtxmlpatterns \
-  -nomake examples \
-  -nomake tests \
-  -nomake tools
-make -j 8
-cd ..
-
-# Build the arm64 variant.
-mkdir qt-5.15.2-arm64
-cd qt-5.15.2-arm64
-../qt-everywhere-src-5.15.2/configure \
-  --prefix=/ \
-  -platform macx-clang \
-  -device-option QMAKE_APPLE_DEVICE_ARCHS=arm64 \
-  -device-option QMAKE_MACOSX_DEPLOYMENT_TARGET=10.13 \
-  -release \
-  -opensource -confirm-license \
-  -gui \
-  -widgets \
-  -no-gif \
-  -no-icu \
-  -no-pch \
-  -no-angle \
-  -no-opengl \
-  -no-dbus \
-  -no-harfbuzz \
-  -skip declarative \
-  -skip multimedia \
-  -skip qtcanvas3d \
-  -skip qtcharts \
-  -skip qtconnectivity \
-  -skip qtdeclarative \
-  -skip qtgamepad \
-  -skip qtlocation \
-  -skip qtmultimedia \
-  -skip qtnetworkauth \
-  -skip qtpurchasing \
-  -skip qtremoteobjects \
-  -skip qtscript \
-  -skip qtsensors \
-  -skip qtserialbus \
-  -skip qtserialport \
-  -skip qtsvg \
-  -skip qtwebchannel \
-  -skip qtwebengine \
-  -skip qtwebsockets \
-  -skip qtxmlpatterns \
-  -nomake examples \
-  -nomake tests \
-  -nomake tools
-make -j 8 -k
-cd ..
-
-# Combine the two builds into universal binaries.
-makeuniversal qt-5.15.2-univ qt-5.15.2-x86_64 qt-5.15.2-arm64
-cd qt-5.15.2-univ
-make install -j 8 INSTALL_ROOT=/tmp/qt-5.15.2-macosx10.13-x86_64-arm64
-cd ..
-
-# Create the final tarball containing universal binaries.
-tar cjf qt-5.15.2-macosx10.13-x86_64-arm64.tar.xz -C /tmp qt-5.15.2-macosx10.13-x86_64-arm64

+ 8 - 6
Utilities/Release/macos/sign-notarize.bash

@@ -91,14 +91,16 @@ readonly vol_name="$(basename "${dmg%.dmg}")"
 readonly vol_path="/Volumes/$vol_name"
 hdiutil attach "${udrw_dmg}"
 
-codesign --verify --timestamp --options=runtime --verbose --deep \
+codesign --verify --timestamp --options=runtime --verbose --force --deep \
   -s "$id" \
   --entitlements "$entitlements_xml" \
-  "$vol_path/CMake.app/Contents/bin/cmake" \
-  "$vol_path/CMake.app/Contents/bin/ccmake" \
-  "$vol_path/CMake.app/Contents/bin/ctest" \
-  "$vol_path/CMake.app/Contents/bin/cpack" \
-  "$vol_path/CMake.app"
+  "$vol_path"/CMake.app/Contents/bin/cmake \
+  "$vol_path"/CMake.app/Contents/bin/ccmake \
+  "$vol_path"/CMake.app/Contents/bin/ctest \
+  "$vol_path"/CMake.app/Contents/bin/cpack \
+  "$vol_path"/CMake.app/Contents/Frameworks/*.framework/Versions/[A56]/Qt* \
+  "$vol_path"/CMake.app/Contents/PlugIns/*/lib*.dylib \
+  "$vol_path"/CMake.app
 
 ditto -c -k --keepParent "$vol_path/CMake.app" "$tmpdir/CMake.app.zip"
 xcrun notarytool submit "$tmpdir/CMake.app.zip" --keychain-profile "$keychain_profile" --wait