Author: cactus Date: Sat Oct 17 23:57:08 2009 GMT Module: packages Tag: DEVEL ---- Log message: - up to 4.6.0 beta1
---- Files affected: packages/qt4: qt4-kde-git.patch (1.1 -> 1.1.2.1) ---- Diffs: ================================================================ Index: packages/qt4/qt4-kde-git.patch diff -u packages/qt4/qt4-kde-git.patch:1.1 packages/qt4/qt4-kde-git.patch:1.1.2.1 --- packages/qt4/qt4-kde-git.patch:1.1 Mon Oct 12 09:48:22 2009 +++ packages/qt4/qt4-kde-git.patch Sun Oct 18 01:57:03 2009 @@ -1,215 +1,8 @@ -diff --git a/README.kde-qt b/README.kde-qt -new file mode 100644 -index 0000000..db3feb6 ---- /dev/null -+++ b/README.kde-qt -@@ -0,0 +1,201 @@ -+This is a patched version of Qt. It may include changes made by KDE -+and Qt developers that have either not been accepted for inclusion -+into Qt, or have been accepted for a later version of Qt than this -+one. -+ -+1. Configuring Qt -+================= -+ -+The recommended compile line is: -+ -+--default-config-begin-- -+ -+ ./configure -qt-gif -debug -fast -no-separate-debug-info \ -+ -system-libpng -system-libjpeg -system-zlib \ -+ -dbus -webkit -plugin-sql-mysql \ -+ -nomake examples -nomake demos -prefix <installdir> -+ -+--default-config-end-- -+ -+It contains "-debug", which greatly improves the use for backtraces (but -+also needs a lot more disk space and makes things slower). To build in -+release mode, replace it with "-release". -+ -+It also contains "-no-separate-debug-info", which disables separate .debug -+files. Instead, the debug information will be built into the libraries. -+This option is needed when you install Qt. -+ -+If you don't install Qt, it can be useful to disable this option, -+thus having separate debug symbol files. With separate debug files, you can -+just move those debug files to another directory to remove Qt debug symbols. -+Moving the files back will enable Qt debug symbols again. -+This is useful if you rarely need to step into Qt functions during debugging, -+because GDB loads much faster and uses less memory without Qt debug symbols. -+In the rare case you need to step into Qt code, you can temporarily enable -+debug symbols again by moving the debug files back. You can even load the Qt -+debug symbols from within GDB on demand, using the "symbol-file" command. -+ -+If you are planning to compile Qt using an Icecream cluster you have to -+pass the option -no-pch (no precompiled headers) to configure to make -+distributed compilation work. -+ -+2. Compiling Qt -+=============== -+ -+To compile Qt on a Unix platform, run: -+ -+ export MAKEFLAGS=-j2 -+ make -+ make install -+ -+If your computer has more than one core or processor, you may consider -+increasing the "2" above. If you've got a compile farm available, you -+should adjust the -j argument to match the number of slots in that -+farm. -+ -+3. Modifying & rebuilding Qt -+============================ -+ -+If you make modifications to the Qt source code, you don't need to -+build everything again. Simply go to the directory containing the -+Makefile closest to the files you changed and run "make" again. -+ -+For example, if you've modified src/corelib/io/qiodevice.cpp, do: -+ -+ cd src/corelib -+ make -+ -+If you make a change that is not temporary, you should create a Git -+commit out of it. However, you shouldn't push those changes to -+kde-qt.git. If you have a fix that benefit others, see the "Creating -+kde-qt.git modifications" section below. -+ -+4. Building Qt examples and demos -+================================= -+ -+The "-nomake examples -nomake demos" arguments to the configure script -+mean that those two sections will not be configured for building, -+which is unneeded for usage of the library. If you want to compile -+the examples or demos later, just enter either directory and type: -+ -+ qmake -+ make -+ -+5. Build Qt tests -+================= -+ -+(Official information: http://qt.gitorious.org/qt/pages/QtAutotestsEnvironment) -+ -+In order to run Qt tests, you must have a "developer build" of Qt. For -+that, you need to reconfigure Qt and add the "-developer-build" -+option. That option is technically equivalent to the options: -+ -+ -debug -prefix $PWD -DQT_BUILD_INTERNAL -+ -+To run a test, go to its source dir in tests/auto/testname. Type -+"make" to build it, then run it (either ./tst_testname, or "make install"). -+ -+6. Building Qt documentation -+============================ -+ -+To build and install the documentation, run: -+ -+ make docs -+ ./config.status -+ make install -+ -+It is necessary to do this once only, even if you rebuild Qt later. -+ -+7. Using Qt uninstalled -+======================= -+ -+To use without having to install it, configure it as follows: -+ -+ ./configure <other configure options> -prefix $PWD -+ make sub-src -+ make sub-tools -+ -+Attention: DO NOT run -+ -+ make install -+ -+If you do, Qt will overwrite your include/ directory with its -+installation. -+ -+8. Creating kde-qt.git modifications -+==================================== -+ -+If you have fixed a bug in Qt or modified it in any way that may -+benefit others, please share your change in the form of a patch. Do -+not commit your changes directly to the main branch because they -+may be lost in a future update if they have not been added to the -+official Qt release. -+ -+The exception to the above rule is that if the fix has been accepted -+by Qt Software (and so will appear in the very next release of Qt), -+then it should be simply cherry-picked from the Qt development -+branch. Note that you shouldn't do this for changes that have been -+accepted into a release which is not the very next. -+In this case, you should use the following command: -+ -+ git cherry-pick -x SHA1_OF_THE_FIX -+where SHA1_OF_THE_FIX is the SHA-1 of the commit that you want to -+introduce. Then push the change to the server. -+ -+Before creating a patch, it is recommended to contact Qt Software -+support via [email protected] and explain the situation. There may -+be a solution for the problem already or a new direction that should -+be accounted for. -+ -+To create a patch, do the following: -+ a) look at the listing of branches in -+ http://qt.gitorious.org/+kde-developers/qt/kde-qt/commits/HEAD and -+ select the next number. -+ -+ b) create a new branch out of a clean, released version of Qt, (for -+ example, 4.5.1), using the number above and a brief description of -+ your fix. For example: -+ git checkout -b patches/0180-window-role v4.5.1 -+ You can see the available released versions of Qt with: -+ git tag -+ -+ c) make your changes to the Qt source code and verify that it -+ compiles, links and works (please run the respective unit tests). -+ -+ c) commit your changes to Git, using the "git commit" command. Please -+ see http://qt.gitorious.org/qt/pages/GitIntroductionWithQt and -+ http://qt.gitorious.org/qt/pages/QtCodingStyle for information on -+ how to create commits -+ Note that you can create multiple commits. -+ -+ e) merge the change to the main branch, for example, 4.5.1-patched: -+ git checkout 4.5.1-patched -+ git merge patches/0180-window-role -+ -+ f) push the changes you made to your branch and to the main server: -+ git push [email protected]:qt/kde-qt.git 4.5.1-patched patches/0180-window-role -+ (Don't forget to list both branch names) -+ -+Don't forget to submit your patch to using the Qt Contribution Model, -+along with the long description of the issue found. See -+http://qt.gitorious.org/qt/pages/QtContributionGuidelines for -+information how. You can submit the branch you've just sent to the -+server. -+ -+9. Troubleshooting: Re-configuring and re-compiling -+================================================== -+ -+For those updating the source in a directory where Qt has already -+been compiled, you may need to run the following commands from the -+top directory of your Qt sources: -+ -+ find . -name '*.moc' | xargs rm -+ -+Sometimes ./configure will refuse to run. You may need to: -+ rm .qmake.cache -+ -+If you think you may have run "make install" on an install-less Qt -+(srcdir == $QTDIR), run: -+ -+ rm -rf include -+ bin/syncqt diff --git a/bin/syncqt b/bin/syncqt -index edabeca..e71d480 100755 +index 6605bfa..8eb43b8 100755 --- a/bin/syncqt +++ b/bin/syncqt -@@ -363,9 +363,13 @@ sub fixPaths { +@@ -365,9 +365,13 @@ sub fixPaths { $match_dir = $tmp; $i = $slash; } @@ -225,10 +18,10 @@ for(my $i = 0; $i < $count; $i++) { $dots .= "../"; diff --git a/configure b/configure -index 4ea1ad0..b28a1fa 100755 +index ea50b37..dbf1b5a 100755 --- a/configure +++ b/configure -@@ -960,6 +960,11 @@ while [ "$#" -gt 0 ]; do +@@ -1020,6 +1020,11 @@ while [ "$#" -gt 0 ]; do VAL=`echo $1 | sed 's,-D,,'` fi ;; @@ -240,7 +33,7 @@ -I?*|-I) VAR="add_ipath" if [ "$1" = "-I" ]; then -@@ -1930,6 +1935,9 @@ while [ "$#" -gt 0 ]; do +@@ -2017,6 +2022,9 @@ while [ "$#" -gt 0 ]; do add_ipath) I_FLAGS="$I_FLAGS -I\"${VAL}\"" ;; @@ -251,10 +44,10 @@ L_FLAGS="$L_FLAGS -L\"${VAL}\"" ;; diff --git a/projects.pro b/projects.pro -index f6c596d..79420d2 100644 +index 2a6a956..c442bed 100644 --- a/projects.pro +++ b/projects.pro -@@ -131,6 +131,9 @@ unix { +@@ -149,6 +149,9 @@ unix { DEFAULT_QMAKESPEC ~= s,^.*mkspecs/,,g mkspecs.commands += $(DEL_FILE) $(INSTALL_ROOT)$$mkspecs.path/default; $(SYMLINK) $$DEFAULT_QMAKESPEC $(INSTALL_ROOT)$$mkspecs.path/default } @@ -265,7 +58,7 @@ false:macx { #mac install location diff --git a/qmake/property.cpp b/qmake/property.cpp -index ea4842a..ac54854 100644 +index 1ee6530..b779756 100644 --- a/qmake/property.cpp +++ b/qmake/property.cpp @@ -81,29 +81,32 @@ QMakeProperty::keyBase(bool version) const @@ -323,10 +116,10 @@ QString version = qmake_version(); if(slash != -1) { diff --git a/src/corelib/global/qnamespace.h b/src/corelib/global/qnamespace.h -index ac2ad34..58d7df0 100644 +index eea7532..9aef3a4 100644 --- a/src/corelib/global/qnamespace.h +++ b/src/corelib/global/qnamespace.h -@@ -895,12 +895,10 @@ public: +@@ -913,12 +913,10 @@ public: Key_Dead_Horn = 0x01001262, // multimedia/internet keys - ignored by default - see QKeyEvent c'tor @@ -339,7 +132,7 @@ Key_VolumeDown = 0x01000070, Key_VolumeMute = 0x01000071, Key_VolumeUp = 0x01000072, -@@ -909,7 +907,6 @@ public: +@@ -927,7 +925,6 @@ public: Key_BassDown = 0x01000075, Key_TrebleUp = 0x01000076, Key_TrebleDown = 0x01000077, @@ -347,7 +140,7 @@ Key_MediaPlay = 0x01000080, Key_MediaStop = 0x01000081, Key_MediaPrevious = 0x01000082, -@@ -918,13 +915,11 @@ public: +@@ -936,13 +933,11 @@ public: #endif Key_MediaNext = 0x01000083, Key_MediaRecord = 0x01000084, @@ -361,7 +154,7 @@ Key_LaunchMail = 0x010000a0, Key_LaunchMedia = 0x010000a1, Key_Launch0 = 0x010000a2, -@@ -943,6 +938,98 @@ public: +@@ -961,6 +956,98 @@ public: Key_LaunchD = 0x010000af, Key_LaunchE = 0x010000b0, Key_LaunchF = 0x010000b1, @@ -460,267 +253,11 @@ Key_MediaLast = 0x0100ffff, -diff --git a/src/corelib/kernel/qeventdispatcher_glib.cpp b/src/corelib/kernel/qeventdispatcher_glib.cpp -index 87e9728..7f6dbb6 100644 ---- a/src/corelib/kernel/qeventdispatcher_glib.cpp -+++ b/src/corelib/kernel/qeventdispatcher_glib.cpp -@@ -127,16 +127,11 @@ struct GTimerSource - GSource source; - QTimerInfoList timerList; - QEventLoop::ProcessEventsFlags processEventsFlags; -+ bool runWithIdlePriority; - }; - --static gboolean timerSourcePrepare(GSource *source, gint *timeout) -+static gboolean timerSourcePrepareHelper(GTimerSource *src, gint *timeout) - { -- gint dummy; -- if (!timeout) -- timeout = &dummy; -- -- GTimerSource *src = reinterpret_cast<GTimerSource *>(source); -- - timeval tv = { 0l, 0l }; - if (!(src->processEventsFlags & QEventLoop::X11ExcludeTimers) && src->timerList.timerWait(tv)) - *timeout = (tv.tv_sec * 1000) + (tv.tv_usec / 1000); -@@ -146,10 +141,8 @@ static gboolean timerSourcePrepare(GSource *source, gint *timeout) - return (*timeout == 0); - } - --static gboolean timerSourceCheck(GSource *source) -+static gboolean timerSourceCheckHelper(GTimerSource *src) - { -- GTimerSource *src = reinterpret_cast<GTimerSource *>(source); -- - if (src->timerList.isEmpty() - || (src->processEventsFlags & QEventLoop::X11ExcludeTimers)) - return false; -@@ -160,9 +153,35 @@ static gboolean timerSourceCheck(GSource *source) - return true; - } - -+static gboolean timerSourcePrepare(GSource *source, gint *timeout) -+{ -+ gint dummy; -+ if (!timeout) -+ timeout = &dummy; -+ -+ GTimerSource *src = reinterpret_cast<GTimerSource *>(source); -+ if (src->runWithIdlePriority) { -+ if (timeout) -+ *timeout = -1; -+ return false; -+ } -+ -+ return timerSourcePrepareHelper(src, timeout); -+} -+ -+static gboolean timerSourceCheck(GSource *source) -+{ -+ GTimerSource *src = reinterpret_cast<GTimerSource *>(source); -+ if (src->runWithIdlePriority) -+ return false; -+ return timerSourceCheckHelper(src); -+} -+ - static gboolean timerSourceDispatch(GSource *source, GSourceFunc, gpointer) - { -- (void) reinterpret_cast<GTimerSource *>(source)->timerList.activateTimers(); -+ GTimerSource *timerSource = reinterpret_cast<GTimerSource *>(source); -+ timerSource->runWithIdlePriority = true; -+ (void) timerSource->timerList.activateTimers(); - return true; // ??? don't remove, right again? - } - -@@ -175,6 +194,53 @@ static GSourceFuncs timerSourceFuncs = { - NULL - }; - -+struct GIdleTimerSource -+{ -+ GSource source; -+ GTimerSource *timerSource; -+}; -+ -+static gboolean idleTimerSourcePrepare(GSource *source, gint *timeout) -+{ -+ GIdleTimerSource *idleTimerSource = reinterpret_cast<GIdleTimerSource *>(source); -+ GTimerSource *timerSource = idleTimerSource->timerSource; -+ if (!timerSource->runWithIdlePriority) { -+ // Yield to the normal priority timer source -+ if (timeout) -+ *timeout = -1; -+ return false; -+ } -+ -+ return timerSourcePrepareHelper(timerSource, timeout); -+} -+ -+static gboolean idleTimerSourceCheck(GSource *source) -+{ -+ GIdleTimerSource *idleTimerSource = reinterpret_cast<GIdleTimerSource *>(source); -+ GTimerSource *timerSource = idleTimerSource->timerSource; -+ if (!timerSource->runWithIdlePriority) { -+ // Yield to the normal priority timer source -+ return false; -+ } -+ return timerSourceCheckHelper(timerSource); -+} -+ -+static gboolean idleTimerSourceDispatch(GSource *source, GSourceFunc, gpointer) -+{ -+ GTimerSource *timerSource = reinterpret_cast<GIdleTimerSource *>(source)->timerSource; -+ (void) timerSourceDispatch(&timerSource->source, 0, 0); -+ return true; -+} -+ -+static GSourceFuncs idleTimerSourceFuncs = { -+ idleTimerSourcePrepare, -+ idleTimerSourceCheck, -+ idleTimerSourceDispatch, -+ NULL, -+ NULL, -+ NULL -+}; -+ - struct GPostEventSource - { - GSource source; -@@ -235,14 +301,15 @@ QEventDispatcherGlibPrivate::QEventDispatcherGlibPrivate(GMainContext *context) - g_main_context_ref(mainContext); - } else { - QCoreApplication *app = QCoreApplication::instance(); -- if (app && QThread::currentThread() == app->thread()) { -- mainContext = g_main_context_default(); -- g_main_context_ref(mainContext); -- } else { -- mainContext = g_main_context_new(); -- } -+ if (app && QThread::currentThread() == app->thread()) { -+ mainContext = g_main_context_default(); -+ g_main_context_ref(mainContext); -+ } else { -+ mainContext = g_main_context_new(); -+ } - } - -+ // setup post event source - postEventSource = reinterpret_cast<GPostEventSource *>(g_source_new(&postEventSourceFuncs, - sizeof(GPostEventSource))); - postEventSource->serialNumber = 1; -@@ -257,14 +324,21 @@ QEventDispatcherGlibPrivate::QEventDispatcherGlibPrivate(GMainContext *context) - g_source_set_can_recurse(&socketNotifierSource->source, true); - g_source_attach(&socketNotifierSource->source, mainContext); - -- // setup timerSource -+ // setup normal and idle timer sources - timerSource = reinterpret_cast<GTimerSource *>(g_source_new(&timerSourceFuncs, - sizeof(GTimerSource))); - (void) new (&timerSource->timerList) QTimerInfoList(); - timerSource->processEventsFlags = QEventLoop::AllEvents; -+ timerSource->runWithIdlePriority = false; - g_source_set_can_recurse(&timerSource->source, true); -- g_source_set_priority(&timerSource->source, G_PRIORITY_DEFAULT_IDLE); - g_source_attach(&timerSource->source, mainContext); -+ -+ idleTimerSource = reinterpret_cast<GIdleTimerSource *>(g_source_new(&idleTimerSourceFuncs, -+ sizeof(GIdleTimerSource))); -+ idleTimerSource->timerSource = timerSource; -+ g_source_set_can_recurse(&idleTimerSource->source, true); -+ g_source_set_priority(&idleTimerSource->source, G_PRIORITY_DEFAULT_IDLE); -+ g_source_attach(&idleTimerSource->source, mainContext); - } - - QEventDispatcherGlib::QEventDispatcherGlib(QObject *parent) -@@ -272,12 +346,9 @@ QEventDispatcherGlib::QEventDispatcherGlib(QObject *parent) - { - } - --QEventDispatcherGlib::QEventDispatcherGlib(GMainContext *mainContext, -- QObject *parent) -- : QAbstractEventDispatcher(*(new QEventDispatcherGlibPrivate(mainContext)), -- parent) --{ --} -+QEventDispatcherGlib::QEventDispatcherGlib(GMainContext *mainContext, QObject *parent) -+ : QAbstractEventDispatcher(*(new QEventDispatcherGlibPrivate(mainContext)), parent) -+{ } - - QEventDispatcherGlib::~QEventDispatcherGlib() - { -@@ -289,6 +360,9 @@ QEventDispatcherGlib::~QEventDispatcherGlib() - g_source_destroy(&d->timerSource->source); - g_source_unref(&d->timerSource->source); - d->timerSource = 0; -+ g_source_destroy(&d->idleTimerSource->source); -+ g_source_unref(&d->idleTimerSource->source); -+ d->idleTimerSource = 0; - - // destroy socket notifier source - for (int i = 0; i < d->socketNotifierSource->pollfds.count(); ++i) { -@@ -324,11 +398,16 @@ bool QEventDispatcherGlib::processEvents(QEventLoop::ProcessEventsFlags flags) - // tell postEventSourcePrepare() and timerSource about any new flags - QEventLoop::ProcessEventsFlags savedFlags = d->timerSource->processEventsFlags; - d->timerSource->processEventsFlags = flags; -- -+ -+ if (!(flags & QEventLoop::EventLoopExec)) { -+ // force timers to be sent at normal priority -+ d->timerSource->runWithIdlePriority = false; -+ } -+ - bool result = g_main_context_iteration(d->mainContext, canWait); - while (!result && canWait) - result = g_main_context_iteration(d->mainContext, canWait); -- -+ - d->timerSource->processEventsFlags = savedFlags; - - if (canWait) -diff --git a/src/corelib/kernel/qeventdispatcher_glib_p.h b/src/corelib/kernel/qeventdispatcher_glib_p.h -index eb7fb75..4103aa3 100644 ---- a/src/corelib/kernel/qeventdispatcher_glib_p.h -+++ b/src/corelib/kernel/qeventdispatcher_glib_p.h -@@ -98,6 +98,7 @@ protected: - struct GPostEventSource; - struct GSocketNotifierSource; - struct GTimerSource; -+struct GIdleTimerSource; - - class Q_CORE_EXPORT QEventDispatcherGlibPrivate : public QAbstractEventDispatcherPrivate - { -@@ -108,6 +109,7 @@ public: - GPostEventSource *postEventSource; - GSocketNotifierSource *socketNotifierSource; - GTimerSource *timerSource; -+ GIdleTimerSource *idleTimerSource; - }; - - QT_END_NAMESPACE -diff --git a/src/corelib/kernel/qeventdispatcher_unix.cpp b/src/corelib/kernel/qeventdispatcher_unix.cpp -index 897bb49..903b0eb 100644 ---- a/src/corelib/kernel/qeventdispatcher_unix.cpp -+++ b/src/corelib/kernel/qeventdispatcher_unix.cpp -@@ -423,10 +423,10 @@ bool QTimerInfoList::timerWait(timeval &tm) - // Find first waiting timer not already active - QTimerInfo *t = 0; - for (QTimerInfoList::const_iterator it = constBegin(); it != constEnd(); ++it) { -- if (!(*it)->inTimerEvent) { -- t = *it; -- break; -- } -+ if (!(*it)->inTimerEvent) { -+ t = *it; -+ break; -+ } - } - - if (!t) diff --git a/src/corelib/kernel/qobject.cpp b/src/corelib/kernel/qobject.cpp -index 1ed0332..089ddfc 100644 +index a8120cf..d1cb510 100644 --- a/src/corelib/kernel/qobject.cpp +++ b/src/corelib/kernel/qobject.cpp -@@ -986,8 +986,16 @@ void QObject::setObjectName(const QString &name) +@@ -1122,8 +1122,16 @@ void QObject::setObjectName(const QString &name) { Q_D(QObject); d->objectName = name; @@ -738,64 +275,35 @@ #ifdef QT3_SUPPORT /*! \internal diff --git a/src/corelib/kernel/qobject_p.h b/src/corelib/kernel/qobject_p.h -index 6ca4dc8..1551472 100644 +index f087407..559b7ff 100644 --- a/src/corelib/kernel/qobject_p.h +++ b/src/corelib/kernel/qobject_p.h -@@ -83,7 +83,9 @@ extern QSignalSpyCallbackSet Q_CORE_EXPORT qt_signal_spy_callback_set; +@@ -83,7 +83,9 @@ void Q_CORE_EXPORT qt_register_signal_spy_callbacks(const QSignalSpyCallbackSet - inline QObjectData::~QObjectData() {} + extern QSignalSpyCallbackSet Q_CORE_EXPORT qt_signal_spy_callback_set; -enum { QObjectPrivateVersion = QT_VERSION }; +// add 0x1000000 to mark it as qt-copy version, with possible modifications +// in some Q*Private class +enum { QObjectPrivateVersion = QT_VERSION + 0x1000000 }; - class Q_CORE_EXPORT QObjectPrivate : public QObjectData <<Diff was trimmed, longer than 597 lines>> ---- CVS-web: http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/qt4/qt4-kde-git.patch?r1=1.1&r2=1.1.2.1&f=u _______________________________________________ pld-cvs-commit mailing list [email protected] http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit
