Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:rhabacker:branches:windows:mingw:win32
mingw32-libalkimia5
0001-cmake-Fix-usage-of-Qt-main-version-with-Qt...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0001-cmake-Fix-usage-of-Qt-main-version-with-Qt-5.15.patch of Package mingw32-libalkimia5
From 0d0ba6d4ba21783d00bffbfaf3dbe57c897d377e Mon Sep 17 00:00:00 2001 From: Ralf Habacker <ralf.habacker@freenet.de> Date: Mon, 1 Apr 2024 12:59:03 +0200 Subject: [PATCH] cmake: Fix usage of Qt main version with Qt < 5.15 The error message on https://build.opensuse.org/package/show/windows:mingw:win32/mingw32-kmymoney5 was 'Could not find a package configuration file provided by "QtCore"'. According to https://doc.qt.io/qt-6/cmake-qt5-and-qt6-compatibility.html#supporting-older-qt-5-versions there is a variable QT_VERSION_MAJOR, not QT_MAJOR_VERSION, which is set with a call to find_package(QT ...). BUG:484865 FIXED-IN:8.1.3 --- CMakeLists.txt | 4 ++++ src/LibAlkimiaConfig.cmake.in | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 2e13944..763614b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -148,6 +148,10 @@ else() endif() set(QT_NETWORK_LIB ${QT_USE_LIBSPREFIX}${QT_NETWORK_COMPONENT}) + # setup QT_VERSION_MAJOR + find_package(QT NAMES Qt5 REQUIRED COMPONENTS Core) + + # find Qt components find_package(Qt5 REQUIRED COMPONENTS Core ${QT_NETWORK_COMPONENT} diff --git a/src/LibAlkimiaConfig.cmake.in b/src/LibAlkimiaConfig.cmake.in index 7b80487..5e5cfb0 100644 --- a/src/LibAlkimiaConfig.cmake.in +++ b/src/LibAlkimiaConfig.cmake.in @@ -8,7 +8,7 @@ if("@BUILD_QT4@" STREQUAL "ON" OR "@BUILD_QT4@" STREQUAL "1") find_package(Qt4 COMPONENTS QtCore QtDBus @QT_NETWORK_LIB@) else() foreach(component Core DBus @QT_BROWSER_COMPONENT@ @QT_NETWORK_COMPONENT@) - set(package Qt@QT_MAJOR_VERSION@${component}) + set(package Qt@QT_VERSION_MAJOR@${component}) message("Search for dependency ${package}") find_dependency(${package} @QT_MIN_VERSION@) endforeach() -- 2.35.3
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor