- support QT_GRAPHICSSYSTEM env

This commit is contained in:
Rex Dieter 2010-05-17 19:56:50 +00:00
parent 2dd6c16d3f
commit a98a335da7
2 changed files with 34 additions and 1 deletions

View File

@ -0,0 +1,28 @@
From 55ef01d93f8257b5927660290fc1ead0b2b74ec9 Mon Sep 17 00:00:00 2001
From: Andreas Hartmetz <ahartmetz@gmail.com>
Date: Thu, 18 Mar 2010 02:41:14 +0100
Subject: [PATCH] Add environment variable switch for graphicssystem so distros and
non-developers can more easily pick a different default.
---
src/gui/kernel/qapplication.cpp | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/src/gui/kernel/qapplication.cpp b/src/gui/kernel/qapplication.cpp
index 49713cf..af83047 100644
--- a/src/gui/kernel/qapplication.cpp
+++ b/src/gui/kernel/qapplication.cpp
@@ -763,6 +763,10 @@ void QApplicationPrivate::construct(
qt_is_gui_used = (qt_appType != QApplication::Tty);
process_cmdline();
+ // the environment variable has the lowest precedence of runtime graphicssystem switches
+ if (graphics_system_name.isEmpty()) {
+ graphics_system_name = QString::fromLocal8Bit(qgetenv("QT_GRAPHICSSYSTEM"));
+ }
// Must be called before initialize()
qt_init(this, qt_appType
#ifdef Q_WS_X11
--
1.6.1

View File

@ -13,7 +13,7 @@ Summary: Qt toolkit
Name: qt
Epoch: 1
Version: 4.6.2
Release: 18%{?dist}
Release: 19%{?dist}
# See LGPL_EXCEPTIONS.txt, LICENSE.GPL3, respectively, for exception details
License: LGPLv2 with exceptions or GPLv3 with exceptions
@ -91,6 +91,7 @@ Patch213: qt-x11-opensource-src-4.6.2-tablet-wacom-QTBUG-8599.patch
Patch214: qt-everywhere-opensource-src-4.6.2-QTBUG-6932.patch
patch215: qt-everywhere-opensource-src-4.6.2-atomic-s390.patch
patch216: qt-everywhere-opensource-src-4.6.2-cups-QTBUG-6471.patch
Patch217: http://qt.gitorious.org/+kde-developers/qt/kde-qt/commit/55ef01d93f8257b5927660290fc1ead0b2b74ec9.patch
Source10: http://gstreamer.freedesktop.org/data/images/artwork/gstreamer-logo.svg
Source11: hi16-phonon-gstreamer.png
@ -457,6 +458,7 @@ Qt libraries used for drawing widgets and OpenGL items.
%patch214 -p1 -b .QTBUG-6932
%patch215 -p1 -b .atomic-s390
%patch216 -p1 -b .cups-QTBUG-6471
%patch217 -p1 -b .QT_GRAPHICSSYSTEM
# drop -fexceptions from $RPM_OPT_FLAGS
RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS | sed 's|-fexceptions||g'`
@ -1052,6 +1054,9 @@ fi
%changelog
* Mon May 17 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.2-19
- support QT_GRAPHICSSYSTEM env
* Thu May 06 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.2-18
- +Provides: qt4-webkit(-devel)