[arch-commits] Commit in openmw/trunk (PKGBUILD qt-5.11.patch)

Evangelos Foutras foutrelis at archlinux.org
Thu May 31 14:02:38 UTC 2018


    Date: Thursday, May 31, 2018 @ 14:02:37
  Author: foutrelis
Revision: 334837

Fix build with Qt 5.11

Added:
  openmw/trunk/qt-5.11.patch
Modified:
  openmw/trunk/PKGBUILD

---------------+
 PKGBUILD      |   13 +++++++--
 qt-5.11.patch |   78 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 88 insertions(+), 3 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2018-05-31 14:02:36 UTC (rev 334836)
+++ PKGBUILD	2018-05-31 14:02:37 UTC (rev 334837)
@@ -10,11 +10,18 @@
 license=('GPL3' 'MIT' 'custom')
 depends=('openal' 'openscenegraph' 'mygui' 'bullet' 'qt5-base' 'ffmpeg' 'sdl2' 'unshield' 'libxt')
 makedepends=('cmake' 'boost' 'doxygen' 'ninja')
-source=("https://github.com/OpenMW/openmw/archive/openmw-${pkgver}.tar.gz")
-sha512sums=('e902dd2274c05838bb1171f07d7a673fc7b85d1290a9e01c8ab89f1c279bd236332ecdc0f2b7944ec7209a0e6022ff472639b5724bf26904e3a2d338c7be401a')
+source=("https://github.com/OpenMW/openmw/archive/openmw-${pkgver}.tar.gz"
+        'qt-5.11.patch')
+sha512sums=('e902dd2274c05838bb1171f07d7a673fc7b85d1290a9e01c8ab89f1c279bd236332ecdc0f2b7944ec7209a0e6022ff472639b5724bf26904e3a2d338c7be401a'
+            'a53775dc3dbdc69ed213fed86382a71768545f9950c59429410c731242d6b43b7e61d4be539c99b5ac87bf92e28be7eb43552c16d30103d1ce50edc853c987de')
 
+prepare() {
+  mkdir -p build
+  cd $pkgname-$pkgname-$pkgver
+  patch -Np1 -i ../qt-5.11.patch
+}
+
 build() {
-  mkdir -p build
   cd build
   cmake "../$pkgname-$pkgname-$pkgver" \
     -DCMAKE_INSTALL_PREFIX=/usr \

Added: qt-5.11.patch
===================================================================
--- qt-5.11.patch	                        (rev 0)
+++ qt-5.11.patch	2018-05-31 14:02:37 UTC (rev 334837)
@@ -0,0 +1,78 @@
+From 2c9d46a60bd8d35f132cb106e5255d590b13640b Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm at gentoo.org>
+Date: Tue, 17 Apr 2018 23:03:56 +0200
+Subject: [PATCH] Fix build with Qt 5.11_beta3 (dropping qt5_use_modules)
+
+---
+ apps/launcher/CMakeLists.txt | 2 +-
+ apps/opencs/CMakeLists.txt   | 2 +-
+ apps/wizard/CMakeLists.txt   | 2 +-
+ components/CMakeLists.txt    | 2 +-
+ extern/osgQt/CMakeLists.txt  | 2 +-
+ 5 files changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/apps/launcher/CMakeLists.txt b/apps/launcher/CMakeLists.txt
+index aec8c2533a..99e7b4daac 100644
+--- a/apps/launcher/CMakeLists.txt
++++ b/apps/launcher/CMakeLists.txt
+@@ -106,7 +106,7 @@ if (DESIRED_QT_VERSION MATCHES 4)
+         target_link_libraries(openmw-launcher ${QT_QTMAIN_LIBRARY})
+     endif(WIN32)
+ else()
+-    qt5_use_modules(openmw-launcher Widgets Core)
++    target_link_libraries(openmw-launcher Qt5::Widgets Qt5::Core)
+ endif()
+ 
+ if (BUILD_WITH_CODE_COVERAGE)
+diff --git a/apps/opencs/CMakeLists.txt b/apps/opencs/CMakeLists.txt
+index b9279bf912..f07b518a98 100644
+--- a/apps/opencs/CMakeLists.txt
++++ b/apps/opencs/CMakeLists.txt
+@@ -246,7 +246,7 @@ if (DESIRED_QT_VERSION MATCHES 4)
+         target_link_libraries(openmw-cs ${QT_QTMAIN_LIBRARY})
+     endif()
+ else()
+-    qt5_use_modules(openmw-cs Widgets Core Network OpenGL)
++    target_link_libraries(openmw-cs Qt5::Widgets Qt5::Core Qt5::Network Qt5::OpenGL)
+ endif()
+ 
+ if (WIN32)
+diff --git a/apps/wizard/CMakeLists.txt b/apps/wizard/CMakeLists.txt
+index 5f7338e520..8d97bbcbfa 100644
+--- a/apps/wizard/CMakeLists.txt
++++ b/apps/wizard/CMakeLists.txt
+@@ -118,7 +118,7 @@ if (DESIRED_QT_VERSION MATCHES 4)
+         target_link_libraries(openmw-wizard ${QT_QTMAIN_LIBRARY})
+     endif()
+ else()
+-    qt5_use_modules(openmw-wizard Widgets Core)
++    target_link_libraries(openmw-wizard Qt5::Widgets Qt5::Core)
+ endif()
+ 
+ if (OPENMW_USE_UNSHIELD)
+diff --git a/components/CMakeLists.txt b/components/CMakeLists.txt
+index 8256f14437..ecb844a9bd 100644
+--- a/components/CMakeLists.txt
++++ b/components/CMakeLists.txt
+@@ -216,7 +216,7 @@ if (USE_QT)
+         ${QT_QTCORE_LIBRARY}
+         ${QT_QTGUI_LIBRARY})
+     else()
+-        qt5_use_modules(components Widgets Core)
++        target_link_libraries(components Qt5::Widgets Qt5::Core)
+     endif()
+ endif()
+ 
+diff --git a/extern/osgQt/CMakeLists.txt b/extern/osgQt/CMakeLists.txt
+index 3bd08a390a..78a4e60344 100644
+--- a/extern/osgQt/CMakeLists.txt
++++ b/extern/osgQt/CMakeLists.txt
+@@ -12,7 +12,7 @@ if (DESIRED_QT_VERSION MATCHES 4)
+     include(${QT_USE_FILE})
+     target_link_libraries(${OSGQT_LIBRARY} ${QT_QTCORE_LIBRARY} ${QT_QTOPENGL_LIBRARY})
+ else()
+-    qt5_use_modules(${OSGQT_LIBRARY} Core OpenGL)
++    target_link_libraries(${OSGQT_LIBRARY} Qt5::Core Qt5::OpenGL)
+ endif()
+ 
+ link_directories(${CMAKE_CURRENT_BINARY_DIR})



More information about the arch-commits mailing list