From d3bfc53697392ee0e505e54fe82b1d55a4a3a435 Mon Sep 17 00:00:00 2001 From: Rex Dieter Date: Sat, 18 Oct 2014 21:20:15 -0500 Subject: [PATCH] fix build on f20 --- qt5-qtbase.spec | 6 +- ... qtbase-opensource-src-5.4.0-old_xcb.patch | 58 +++++++++---------- 2 files changed, 33 insertions(+), 31 deletions(-) rename qtbase-opensource-src-5.3.2-old_xcb.patch => qtbase-opensource-src-5.4.0-old_xcb.patch (72%) diff --git a/qt5-qtbase.spec b/qt5-qtbase.spec index 61451d4..7570736 100644 --- a/qt5-qtbase.spec +++ b/qt5-qtbase.spec @@ -57,7 +57,7 @@ Source6: 10-qt5-check-opengl2.sh # support the old version of libxcb and the resulting lack of libxkbcommon-x11 # in F19 and F20 -Patch0: qtbase-opensource-src-5.3.2-old_xcb.patch +Patch0: qtbase-opensource-src-5.4.0-old_xcb.patch # support the old version of libxkbcommon in F19 and F20 Patch1: qtbase-opensource-src-5.3.2-old_xkbcommon.patch @@ -155,8 +155,10 @@ BuildRequires: pkgconfig(gbm) BuildRequires: pkgconfig(glesv2) BuildRequires: pkgconfig(sqlite3) >= 3.7 %define sqlite -system-sqlite -BuildRequires: pkgconfig(harfbuzz) >= 0.9.19 +%if 0%{?fedora} > 20 +BuildRequires: pkgconfig(harfbuzz) >= 0.9.31 %define harfbuzz -system-harfbuzz +%endif BuildRequires: pkgconfig(icu-i18n) BuildRequires: pkgconfig(libpcre) >= 8.30 %define pcre -system-pcre diff --git a/qtbase-opensource-src-5.3.2-old_xcb.patch b/qtbase-opensource-src-5.4.0-old_xcb.patch similarity index 72% rename from qtbase-opensource-src-5.3.2-old_xcb.patch rename to qtbase-opensource-src-5.4.0-old_xcb.patch index 0f6ce5b..c3d3c38 100644 --- a/qtbase-opensource-src-5.3.2-old_xcb.patch +++ b/qtbase-opensource-src-5.4.0-old_xcb.patch @@ -1,7 +1,7 @@ -diff -ur qtbase-opensource-src-5.3.2/configure qtbase-opensource-src-5.3.2-old_xcb/configure ---- qtbase-opensource-src-5.3.2/configure 2014-09-11 12:47:55.000000000 +0200 -+++ qtbase-opensource-src-5.3.2-old_xcb/configure 2014-10-08 19:46:02.000000000 +0200 -@@ -4982,10 +4982,8 @@ +diff -up qtbase-opensource-src-5.4.0-beta/configure.old_xcb qtbase-opensource-src-5.4.0-beta/configure +--- qtbase-opensource-src-5.4.0-beta/configure.old_xcb 2014-10-14 11:39:39.000000000 -0500 ++++ qtbase-opensource-src-5.4.0-beta/configure 2014-10-18 20:47:25.924959443 -0500 +@@ -5040,10 +5040,8 @@ if [ "$CFG_XCB" != "no" ]; then QMAKE_LIBS_XCB="`$PKG_CONFIG --libs $XCB_PACKAGES 2>/dev/null`" fi @@ -13,10 +13,10 @@ diff -ur qtbase-opensource-src-5.3.2/configure qtbase-opensource-src-5.3.2-old_x QMAKE_CFLAGS_XKB="`$PKG_CONFIG --cflags xcb xcb-xkb 2>/dev/null`" QMAKE_LIBS_XKB="`$PKG_CONFIG --libs xcb xcb-xkb 2>/dev/null`" if compileTest qpa/xcb-xkb "xcb-xkb" $QMAKE_CFLAGS_XKB $QMAKE_LIBS_XKB; then -@@ -5092,9 +5090,9 @@ - # currently only xcb platform plugin supports building xkbcommon +@@ -5150,16 +5148,16 @@ MIN_REQ_XKBCOMMON="0.4.1" if [ "$CFG_XCB" != "no" ]; then - if [ "$CFG_XKBCOMMON" = "auto" ] || [ "$CFG_XKBCOMMON" = "system" ]; then + if [ "$CFG_XKBCOMMON" != "no" ] && [ "$CFG_XKBCOMMON" != "qt" ]; then + # Check if there is a suitable system-wide xkbcommon - if [ -n "$PKG_CONFIG" ] && $PKG_CONFIG --exists "xkbcommon xkbcommon-x11 >= $MIN_REQ_XKBCOMMON" 2>/dev/null; then - QMAKE_CFLAGS_XKBCOMMON="`$PKG_CONFIG --cflags xkbcommon xkbcommon-x11 2>/dev/null`" - QMAKE_LIBS_XKBCOMMON="`$PKG_CONFIG --libs xkbcommon xkbcommon-x11 2>/dev/null`" @@ -26,19 +26,19 @@ diff -ur qtbase-opensource-src-5.3.2/configure qtbase-opensource-src-5.3.2-old_x QMakeVar set QMAKE_CFLAGS_XKBCOMMON "$QMAKE_CFLAGS_XKBCOMMON" QMakeVar set QMAKE_LIBS_XKBCOMMON "$QMAKE_LIBS_XKBCOMMON" -@@ -6588,7 +6586,7 @@ - echo - fi - if [ "$ORIG_CFG_XKBCOMMON" != qt ] && [ "$CFG_XKBCOMMON" = qt ]; then -- echo "NOTE: libxkbcommon and libxkbcommon-x11 $MIN_REQ_XKBCOMMON or higher not found on the system, will use " -+ echo "NOTE: libxkbcommon $MIN_REQ_XKBCOMMON or higher not found on the system, will use " - echo "the bundled version from 3rd party directory." - fi - if [ "$CFG_XKBCOMMON" = "qt" ] && [ "$CFG_XKB_CONFIG_ROOT" = "not found" ]; then -diff -ur qtbase-opensource-src-5.3.2/src/plugins/platforms/xcb/qxcbconnection.cpp qtbase-opensource-src-5.3.2-old_xcb/src/plugins/platforms/xcb/qxcbconnection.cpp ---- qtbase-opensource-src-5.3.2/src/plugins/platforms/xcb/qxcbconnection.cpp 2014-09-11 12:48:06.000000000 +0200 -+++ qtbase-opensource-src-5.3.2-old_xcb/src/plugins/platforms/xcb/qxcbconnection.cpp 2014-10-08 19:46:02.000000000 +0200 -@@ -1710,7 +1710,7 @@ + CFG_XKBCOMMON=system + elif [ "$CFG_XKBCOMMON" = "system" ] && [ "$CFG_CONFIGURE_EXIT_ON_ERROR" = "yes" ]; then +- echo " xkbcommon support cannot be enabled because either xkbcommon or " +- echo " xkbcommon-x11 >= $MIN_REQ_XKBCOMMON was not found via pkg-config!" ++ echo " xkbcommon support cannot be enabled because xkbcommon" ++ echo " >= $MIN_REQ_XKBCOMMON was not found via pkg-config!" + echo " Turn on verbose messaging (-v) to $0 to see the final report." + echo " If you believe this message is in error you may use the continue" + echo " switch (-continue) to $0 to continue." +diff -up qtbase-opensource-src-5.4.0-beta/src/plugins/platforms/xcb/qxcbconnection.cpp.old_xcb qtbase-opensource-src-5.4.0-beta/src/plugins/platforms/xcb/qxcbconnection.cpp +--- qtbase-opensource-src-5.4.0-beta/src/plugins/platforms/xcb/qxcbconnection.cpp.old_xcb 2014-10-14 11:40:06.000000000 -0500 ++++ qtbase-opensource-src-5.4.0-beta/src/plugins/platforms/xcb/qxcbconnection.cpp 2014-10-18 20:42:22.996088321 -0500 +@@ -1751,7 +1751,7 @@ void QXcbConnection::initializeXKB() xcb_xkb_use_extension_cookie_t xkb_query_cookie; xcb_xkb_use_extension_reply_t *xkb_query; @@ -47,10 +47,10 @@ diff -ur qtbase-opensource-src-5.3.2/src/plugins/platforms/xcb/qxcbconnection.cp xkb_query = xcb_xkb_use_extension_reply(c, xkb_query_cookie, 0); if (!xkb_query) { -diff -ur qtbase-opensource-src-5.3.2/src/plugins/platforms/xcb/qxcbkeyboard.cpp qtbase-opensource-src-5.3.2-old_xcb/src/plugins/platforms/xcb/qxcbkeyboard.cpp ---- qtbase-opensource-src-5.3.2/src/plugins/platforms/xcb/qxcbkeyboard.cpp 2014-09-11 12:48:06.000000000 +0200 -+++ qtbase-opensource-src-5.3.2-old_xcb/src/plugins/platforms/xcb/qxcbkeyboard.cpp 2014-10-08 19:46:02.000000000 +0200 -@@ -697,50 +697,65 @@ +diff -up qtbase-opensource-src-5.4.0-beta/src/plugins/platforms/xcb/qxcbkeyboard.cpp.old_xcb qtbase-opensource-src-5.4.0-beta/src/plugins/platforms/xcb/qxcbkeyboard.cpp +--- qtbase-opensource-src-5.4.0-beta/src/plugins/platforms/xcb/qxcbkeyboard.cpp.old_xcb 2014-10-14 11:40:06.000000000 -0500 ++++ qtbase-opensource-src-5.4.0-beta/src/plugins/platforms/xcb/qxcbkeyboard.cpp 2014-10-18 20:42:22.997088344 -0500 +@@ -693,50 +693,65 @@ void QXcbKeyboard::updateKeymap() // log only critical errors, we do our own error logging from printKeymapError() xkb_context_set_log_level(xkb_context, (xkb_log_level)XKB_LOG_LEVEL_CRITICAL); } @@ -151,7 +151,7 @@ diff -ur qtbase-opensource-src-5.3.2/src/plugins/platforms/xcb/qxcbkeyboard.cpp } #ifndef QT_NO_XKB -@@ -995,11 +1010,23 @@ +@@ -993,11 +1008,23 @@ QXcbKeyboard::QXcbKeyboard(QXcbConnectio if (connection->hasXKB()) { updateVModMapping(); updateVModToRModMapping(); @@ -177,10 +177,10 @@ diff -ur qtbase-opensource-src-5.3.2/src/plugins/platforms/xcb/qxcbkeyboard.cpp } else { #endif m_key_symbols = xcb_key_symbols_alloc(xcb_connection()); -diff -ur qtbase-opensource-src-5.3.2/src/plugins/platforms/xcb/qxcbkeyboard.h qtbase-opensource-src-5.3.2-old_xcb/src/plugins/platforms/xcb/qxcbkeyboard.h ---- qtbase-opensource-src-5.3.2/src/plugins/platforms/xcb/qxcbkeyboard.h 2014-09-11 12:48:06.000000000 +0200 -+++ qtbase-opensource-src-5.3.2-old_xcb/src/plugins/platforms/xcb/qxcbkeyboard.h 2014-10-08 19:46:02.000000000 +0200 -@@ -47,9 +47,6 @@ +diff -up qtbase-opensource-src-5.4.0-beta/src/plugins/platforms/xcb/qxcbkeyboard.h.old_xcb qtbase-opensource-src-5.4.0-beta/src/plugins/platforms/xcb/qxcbkeyboard.h +--- qtbase-opensource-src-5.4.0-beta/src/plugins/platforms/xcb/qxcbkeyboard.h.old_xcb 2014-10-14 11:40:06.000000000 -0500 ++++ qtbase-opensource-src-5.4.0-beta/src/plugins/platforms/xcb/qxcbkeyboard.h 2014-10-18 20:42:22.997088344 -0500 +@@ -39,9 +39,6 @@ #include #include