diff options
author | Christian Tismer <tismer@stackless.com> | 2022-03-17 18:06:23 +0100 |
---|---|---|
committer | Christian Tismer <tismer@stackless.com> | 2022-03-21 08:09:00 +0100 |
commit | 5c540f92e510082d0eaef97487420880503dbbfb (patch) | |
tree | 48315f8220e09e648ac7700b54dbd6fe605fad6b | |
parent | 539b13ca6f5e826791d9759047a6b385a73627c8 (diff) |
Fix scriptableapplication to build on macOS with framework Qt, amend
The original fix worked with qmake, but the cmake version
has a bug. The setting for "qt_core_library_location_dir"
was two levels too deep.
This fixes the cmake build as-is.
The next check-in removes qmake and uses Ninja.
Amends {471b05f35a9c57d7fa910cf9f11c7f5fdfbf2a93}
Task-number: PYSIDE-623
Change-Id: I288f2e9cd9479843718fa8b498ded51c9c6b140b
Pick-to: 6.2
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
-rw-r--r-- | examples/scriptableapplication/CMakeLists.txt | 5 | ||||
-rw-r--r-- | testing/wheel_tester.py | 11 |
2 files changed, 8 insertions, 8 deletions
diff --git a/examples/scriptableapplication/CMakeLists.txt b/examples/scriptableapplication/CMakeLists.txt index 8cb58a330..ae4429a14 100644 --- a/examples/scriptableapplication/CMakeLists.txt +++ b/examples/scriptableapplication/CMakeLists.txt @@ -75,8 +75,9 @@ endforeach() get_target_property(QtCore_is_framework Qt6::Core FRAMEWORK) if (QtCore_is_framework) get_target_property(qt_core_library_location Qt6::Core LOCATION) - get_filename_component(qt_core_library_location_dir "${qt_core_library_location}" DIRECTORY) - get_filename_component(lib_dir "${qt_core_library_location_dir}/../" ABSOLUTE) + # PYSIDE-623: We move up until the directory contains all the frameworks. + # This is "lib" in ".../lib/QtCore.framework/Versions/A/QtCore". + get_filename_component(lib_dir "${qt_core_library_location}/../../../.." ABSOLUTE) list(APPEND INCLUDES "--framework-include-paths=${lib_dir}") endif() diff --git a/testing/wheel_tester.py b/testing/wheel_tester.py index 5dfb73041..39b93ef42 100644 --- a/testing/wheel_tester.py +++ b/testing/wheel_tester.py @@ -342,12 +342,11 @@ def try_build_examples(): run_make_install() execute_script(os.path.join(src_path, "main.py")) - log.info("*** Defunct: build scriptableapplication using cmake.") - # log.info("Attempting to build scriptableapplication using cmake.") - # src_path = os.path.join(examples_dir, "scriptableapplication") - # prepare_build_folder(src_path, "cmake") - # generate_build_cmake() - # run_make() + log.info("Attempting to build scriptableapplication using cmake.") + src_path = os.path.join(examples_dir, "scriptableapplication") + prepare_build_folder(src_path, "cmake") + generate_build_cmake() + run_make() log.info("Attempting to build scriptableapplication using qmake.") src_path = os.path.join(examples_dir, "scriptableapplication") |