summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorFelix Schindler2015-06-20 15:54:41 +0200
committerFelix Schindler2015-06-20 15:54:41 +0200
commitb6f4064f95efba89cb564fb56d697944b014a5a5 (patch)
tree5af7284169336059dd8efd3e2c98d9690ecdd156
downloadaur-b6f4064f95efba89cb564fb56d697944b014a5a5.tar.gz
add state of https://github.com/ftalbrecht/aur, rev. 84761b9
-rw-r--r--.SRCINFO179
-rw-r--r--.gitignore1
-rw-r--r--CVE-2013-4549.patch235
-rw-r--r--PKGBUILD448
-rw-r--r--assistant-qt51.desktop8
-rw-r--r--bison3.patch38
-rw-r--r--designer-qt51.desktop10
-rw-r--r--libmng2.patch34
-rw-r--r--linguist-qt51.desktop9
-rw-r--r--qdbusviewer-qt51.desktop9
-rw-r--r--qt5-tools.install12
-rw-r--r--qt51.PATH4
-rw-r--r--use-python2.patch118
13 files changed, 1105 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..beeb48d60fc
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,179 @@
+# Generated by makepkg 4.2.1
+# Sat Jun 20 11:55:55 UTC 2015
+pkgbase = qt51
+ pkgver = 5.1.1
+ pkgrel = 2
+ url = http://qt-project.org/
+ arch = i686
+ arch = x86_64
+ groups = qt51
+ license = GPL3
+ license = LGPL
+ license = FDL
+ license = custom
+ makedepends = libxcb
+ makedepends = xcb-proto
+ makedepends = xcb-util
+ makedepends = xcb-util-image
+ makedepends = xcb-util-wm
+ makedepends = xcb-util-keysyms
+ makedepends = mesa
+ makedepends = at-spi2-core
+ makedepends = alsa-lib
+ makedepends = gstreamer0.10-base-plugins
+ makedepends = libmng
+ makedepends = libjpeg-turbo
+ makedepends = cups
+ makedepends = libpulse
+ makedepends = hicolor-icon-theme
+ makedepends = desktop-file-utils
+ makedepends = postgresql-libs
+ makedepends = libmariadbclient
+ makedepends = sqlite
+ makedepends = unixodbc
+ makedepends = libfbclient
+ makedepends = python2
+ makedepends = ruby
+ makedepends = gperf
+ makedepends = libxslt
+ makedepends = libxcomposite
+ makedepends = fontconfig
+ makedepends = openal
+ makedepends = gtk2
+ makedepends = libxkbcommon
+ source = http://download.qt-project.org/official_releases/qt/5.1/5.1.1/single/qt-everywhere-opensource-src-5.1.1.tar.xz
+ source = assistant-qt51.desktop
+ source = designer-qt51.desktop
+ source = linguist-qt51.desktop
+ source = qdbusviewer-qt51.desktop
+ source = use-python2.patch
+ source = bison3.patch
+ source = CVE-2013-4549.patch
+ source = libmng2.patch
+ source = qt51.PATH
+ md5sums = 697b7b8768ef8895e168366ab6b44760
+ md5sums = d6fd35a4858c2519385d13c04985a947
+ md5sums = bc63cf356e5cbe40ca542ffc1c5fe4ab
+ md5sums = 4ce959cbe138df8589e81537ac40f37f
+ md5sums = 9019f5c97c91c9b29a50b55f3e33c40a
+ md5sums = 92831f79144d5cb8121915423ba47575
+ md5sums = 6b162cd2bc104f0ae83ca039401be7bf
+ md5sums = e59ba552e12408dcc9486cdbb1f233e3
+ md5sums = 478647fa057d190a7d789cf78995167b
+ md5sums = 28f4755e54ba1df5a89d60a73f6d1a9e
+
+pkgname = qt51-base
+ pkgdesc = A cross-platform application and UI framework (5.1.x)
+ depends = libjpeg-turbo
+ depends = xcb-util-keysyms
+ depends = libgl
+ depends = dbus
+ depends = fontconfig
+ depends = systemd
+ depends = xcb-util-wm
+ depends = libxrender
+ depends = libxi
+ depends = sqlite
+ depends = libpng
+ depends = xcb-util-image
+ depends = icu
+ depends = qtchooser
+ depends = libxkbcommon
+ optdepends = postgresql-libs: PostgreSQL driver
+ optdepends = libmariadbclient: MariaDB driver
+ optdepends = unixodbc: ODBC driver
+ optdepends = libfbclient: Firebird/iBase driver
+ options = staticlibs
+
+pkgname = qt51-declarative
+ pkgdesc = A cross-platform application and UI framework (QtQml, QtQuick) (5.1.x)
+ depends = qt51-jsbackend
+ depends = qt51-xmlpatterns
+
+pkgname = qt51-doc
+ pkgdesc = A cross-platform application and UI framework (Documentation) (5.1.x)
+ groups =
+ depends = qt51-base
+ options = docs
+ options = !emptydirs
+
+pkgname = qt51-graphicaleffects
+ pkgdesc = A cross-platform application and UI framework (QtGraphicalEffects) (5.1.x)
+ depends = qt51-declarative
+
+pkgname = qt51-imageformats
+ pkgdesc = A cross-platform application and UI framework (Images plugins) (5.1.x)
+ depends = qt51-base
+ depends = libtiff
+ depends = libmng
+
+pkgname = qt51-jsbackend
+ pkgdesc = A cross-platform application and UI framework (QtV8) (5.1.x)
+ depends = qt51-base
+
+pkgname = qt51-multimedia
+ pkgdesc = A cross-platform application and UI framework (QtMultimedia) (5.1.x)
+ depends = qt51-declarative
+ depends = libpulse
+ depends = gstreamer0.10-base
+ depends = openal
+
+pkgname = qt51-quick1
+ pkgdesc = A cross-platform application and UI framework (QtDeclarative) (5.1.x)
+ depends = qt51-webkit
+ depends = qt51-script
+
+pkgname = qt51-quickcontrols
+ pkgdesc = A cross-platform application and UI framework (QtQuick) (5.1.x)
+ depends = qt51-declarative
+
+pkgname = qt51-script
+ pkgdesc = A cross-platform application and UI framework (QtScript) (5.1.x)
+ depends = qt51-base
+
+pkgname = qt51-sensors
+ pkgdesc = A cross-platform application and UI framework (QtSensors) (5.1.x)
+ depends = qt51-declarative
+
+pkgname = qt51-serialport
+ pkgdesc = A cross-platform application and UI framework (QtSerialPort) (5.1.x)
+ depends = qt51-base
+
+pkgname = qt51-svg
+ pkgdesc = A cross-platform application and UI framework (QtSvg) (5.1.x)
+ depends = qt51-base
+
+pkgname = qt51-tools
+ pkgdesc = A cross-platform application and UI framework (Development Tools, QtHelp) (5.1.x)
+ install = qt5-tools.install
+ depends = qt51-webkit
+ depends = desktop-file-utils
+ depends = qt51-translations
+ depends = hicolor-icon-theme
+ depends = xdg-utils
+ optdepends = qt51-doc: documentation
+ options = staticlibs
+
+pkgname = qt51-translations
+ pkgdesc = A cross-platform application and UI framework (Translations) (5.1.x)
+ depends = qt51-base
+
+pkgname = qt51-webkit
+ pkgdesc = A cross-platform application and UI framework (QtWebKit) (5.1.x)
+ license = GPL3
+ license = LGPL
+ license = FDL
+ depends = qt51-declarative
+ depends = gstreamer0.10-base
+ depends = libxslt
+ depends = libxcomposite
+ depends = qt51-sensors
+
+pkgname = qt51-x11extras
+ pkgdesc = A cross-platform application and UI framework (QtX11Extras) (5.1.x)
+ depends = qt51-base
+
+pkgname = qt51-xmlpatterns
+ pkgdesc = A cross-platform application and UI framework (QtXmlPatterns) (5.1.x)
+ depends = qt51-base
+
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 00000000000..3618180ade0
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1 @@
+qt-everywhere-opensource-src-5.1.1.tar.xz
diff --git a/CVE-2013-4549.patch b/CVE-2013-4549.patch
new file mode 100644
index 00000000000..6111aa8fe10
--- /dev/null
+++ b/CVE-2013-4549.patch
@@ -0,0 +1,235 @@
+From 46a8885ae486e238a39efa5119c2714f328b08e4 Mon Sep 17 00:00:00 2001
+From: Mitch Curtis <mitch.curtis@digia.com>
+Date: Fri, 27 Sep 2013 12:32:28 +0200
+Subject: [PATCH] Disallow deep or widely nested entity references.
+
+Nested references with a depth of 2 or greater will fail. References
+that partially expand to greater than 1024 characters will also fail.
+
+Change-Id: Id4e49d6f7cf51e3a247efdb4c6c7c9bd9b223f6e
+Reviewed-by: Richard J. Moore <rich@kde.org>
+Reviewed-by: Lars Knoll <lars.knoll@digia.com>
+
+From f1053d94f59f053ce4acad9320df14f1fbe4faac Mon Sep 17 00:00:00 2001
+From: Mitch Curtis <mitch.curtis@digia.com>
+Date: Mon, 11 Nov 2013 14:27:40 +0100
+Subject: [PATCH] Fully expand entities to ensure deep or widely nested ones fail parsing
+
+With 46a8885ae486e238a39efa5119c2714f328b08e4, we failed when parsing
+entities whose partially expanded size was greater than 1024
+characters. That was not enough, so now we fully expand all entities.
+
+Amends 46a8885ae486e238a39efa5119c2714f328b08e4.
+
+Change-Id: Ie80720d7e04d825eb4eebf528140eb94806c02b1
+Reviewed-by: Richard J. Moore <rich@kde.org>
+Reviewed-by: Lars Knoll <lars.knoll@digia.com>
+
+diff --git a/src/xml/sax/qxml.cpp b/src/xml/sax/qxml.cpp
+index 45c0f3e..e6d78d3 100644
+--- a/src/xml/sax/qxml.cpp
++++ b/src/xml/sax/qxml.cpp
+@@ -424,6 +424,10 @@ private:
+ int stringValueLen;
+ QString emptyStr;
+
++ // The limit to the amount of times the DTD parsing functions can be called
++ // for the DTD currently being parsed.
++ int dtdRecursionLimit;
++
+ const QString &string();
+ void stringClear();
+ void stringAddC(QChar);
+@@ -493,6 +497,8 @@ private:
+ void parseFailed(ParseFunction where, int state);
+ void pushParseState(ParseFunction function, int state);
+
++ bool isPartiallyExpandedEntityValueTooLarge(QString *errorMessage);
++
+ Q_DECLARE_PUBLIC(QXmlSimpleReader)
+ QXmlSimpleReader *q_ptr;
+
+@@ -2757,6 +2763,8 @@ QXmlSimpleReaderPrivate::QXmlSimpleReaderPrivate(QXmlSimpleReader *reader)
+ useNamespacePrefixes = false;
+ reportWhitespaceCharData = true;
+ reportEntities = false;
++
++ dtdRecursionLimit = 2;
+ }
+
+ QXmlSimpleReaderPrivate::~QXmlSimpleReaderPrivate()
+@@ -5035,6 +5043,11 @@ bool QXmlSimpleReaderPrivate::parseDoctype()
+ }
+ break;
+ case Mup:
++ if (dtdRecursionLimit > 0 && parameterEntities.size() > dtdRecursionLimit) {
++ reportParseError(QString::fromLatin1(
++ "DTD parsing exceeded recursion limit of %1.").arg(dtdRecursionLimit));
++ return false;
++ }
+ if (!parseMarkupdecl()) {
+ parseFailed(&QXmlSimpleReaderPrivate::parseDoctype, state);
+ return false;
+@@ -6644,6 +6657,37 @@ bool QXmlSimpleReaderPrivate::parseChoiceSeq()
+ return false;
+ }
+
++bool QXmlSimpleReaderPrivate::isPartiallyExpandedEntityValueTooLarge(QString *errorMessage)
++{
++ const QString value = string();
++ QMap<QString, int> referencedEntityCounts;
++ foreach (QString entityName, entities.keys()) {
++ for (int i = 0; i < value.size() && i != -1; ) {
++ i = value.indexOf(entityName, i);
++ if (i != -1) {
++ // The entityName we're currently trying to find
++ // was matched in this string; increase our count.
++ ++referencedEntityCounts[entityName];
++ i += entityName.size();
++ }
++ }
++ }
++
++ foreach (QString entityName, referencedEntityCounts.keys()) {
++ const int timesReferenced = referencedEntityCounts[entityName];
++ const QString entityValue = entities[entityName];
++ if (entityValue.size() * timesReferenced > 1024) {
++ if (errorMessage) {
++ *errorMessage = QString::fromLatin1("The XML entity \"%1\""
++ "expands too a string that is too large to process when "
++ "referencing \"%2\" %3 times.").arg(entityName).arg(entityName).arg(timesReferenced);
++ }
++ return true;
++ }
++ }
++ return false;
++}
++
+ /*
+ Parse a EntityDecl [70].
+
+@@ -6738,6 +6782,15 @@ bool QXmlSimpleReaderPrivate::parseEntityDecl()
+ switch (state) {
+ case EValue:
+ if ( !entityExist(name())) {
++ QString errorMessage;
++ if (isPartiallyExpandedEntityValueTooLarge(&errorMessage)) {
++ // The entity at entityName is entityValue.size() characters
++ // long in its unexpanded form, and was mentioned timesReferenced times,
++ // resulting in a string that would be greater than 1024 characters.
++ reportParseError(errorMessage);
++ return false;
++ }
++
+ entities.insert(name(), string());
+ if (declHnd) {
+ if (!declHnd->internalEntityDecl(name(), string())) {
+diff --git a/src/xml/sax/qxml.cpp b/src/xml/sax/qxml.cpp
+index e6d78d3..f3a1e47 100644
+--- a/src/xml/sax/qxml.cpp
++++ b/src/xml/sax/qxml.cpp
+@@ -426,7 +426,9 @@ private:
+
+ // The limit to the amount of times the DTD parsing functions can be called
+ // for the DTD currently being parsed.
+- int dtdRecursionLimit;
++ static const int dtdRecursionLimit = 2;
++ // The maximum amount of characters an entity value may contain, after expansion.
++ static const int entityCharacterLimit = 1024;
+
+ const QString &string();
+ void stringClear();
+@@ -497,7 +499,7 @@ private:
+ void parseFailed(ParseFunction where, int state);
+ void pushParseState(ParseFunction function, int state);
+
+- bool isPartiallyExpandedEntityValueTooLarge(QString *errorMessage);
++ bool isExpandedEntityValueTooLarge(QString *errorMessage);
+
+ Q_DECLARE_PUBLIC(QXmlSimpleReader)
+ QXmlSimpleReader *q_ptr;
+@@ -2763,8 +2765,6 @@ QXmlSimpleReaderPrivate::QXmlSimpleReaderPrivate(QXmlSimpleReader *reader)
+ useNamespacePrefixes = false;
+ reportWhitespaceCharData = true;
+ reportEntities = false;
+-
+- dtdRecursionLimit = 2;
+ }
+
+ QXmlSimpleReaderPrivate::~QXmlSimpleReaderPrivate()
+@@ -6657,30 +6657,43 @@ bool QXmlSimpleReaderPrivate::parseChoiceSeq()
+ return false;
+ }
+
+-bool QXmlSimpleReaderPrivate::isPartiallyExpandedEntityValueTooLarge(QString *errorMessage)
++bool QXmlSimpleReaderPrivate::isExpandedEntityValueTooLarge(QString *errorMessage)
+ {
+- const QString value = string();
+- QMap<QString, int> referencedEntityCounts;
+- foreach (QString entityName, entities.keys()) {
+- for (int i = 0; i < value.size() && i != -1; ) {
+- i = value.indexOf(entityName, i);
+- if (i != -1) {
+- // The entityName we're currently trying to find
+- // was matched in this string; increase our count.
+- ++referencedEntityCounts[entityName];
+- i += entityName.size();
++ QMap<QString, int> literalEntitySizes;
++ // The entity at (QMap<QString,) referenced the entities at (QMap<QString,) (int>) times.
++ QMap<QString, QMap<QString, int> > referencesToOtherEntities;
++ QMap<QString, int> expandedSizes;
++
++ // For every entity, check how many times all entity names were referenced in its value.
++ foreach (QString toSearch, entities.keys()) {
++ // The amount of characters that weren't entity names, but literals, like 'X'.
++ QString leftOvers = entities.value(toSearch);
++ // How many times was entityName referenced by toSearch?
++ foreach (QString entityName, entities.keys()) {
++ for (int i = 0; i < leftOvers.size() && i != -1; ) {
++ i = leftOvers.indexOf(QString::fromLatin1("&%1;").arg(entityName), i);
++ if (i != -1) {
++ leftOvers.remove(i, entityName.size() + 2);
++ // The entityName we're currently trying to find was matched in this string; increase our count.
++ ++referencesToOtherEntities[toSearch][entityName];
++ }
+ }
+ }
++ literalEntitySizes[toSearch] = leftOvers.size();
+ }
+
+- foreach (QString entityName, referencedEntityCounts.keys()) {
+- const int timesReferenced = referencedEntityCounts[entityName];
+- const QString entityValue = entities[entityName];
+- if (entityValue.size() * timesReferenced > 1024) {
++ foreach (QString entity, referencesToOtherEntities.keys()) {
++ expandedSizes[entity] = literalEntitySizes[entity];
++ foreach (QString referenceTo, referencesToOtherEntities.value(entity).keys()) {
++ const int references = referencesToOtherEntities.value(entity).value(referenceTo);
++ // The total size of an entity's value is the expanded size of all of its referenced entities, plus its literal size.
++ expandedSizes[entity] += expandedSizes[referenceTo] * references + literalEntitySizes[referenceTo] * references;
++ }
++
++ if (expandedSizes[entity] > entityCharacterLimit) {
+ if (errorMessage) {
+- *errorMessage = QString::fromLatin1("The XML entity \"%1\""
+- "expands too a string that is too large to process when "
+- "referencing \"%2\" %3 times.").arg(entityName).arg(entityName).arg(timesReferenced);
++ *errorMessage = QString::fromLatin1("The XML entity \"%1\" expands too a string that is too large to process (%2 characters > %3).");
++ *errorMessage = (*errorMessage).arg(entity).arg(expandedSizes[entity]).arg(entityCharacterLimit);
+ }
+ return true;
+ }
+@@ -6783,10 +6796,7 @@ bool QXmlSimpleReaderPrivate::parseEntityDecl()
+ case EValue:
+ if ( !entityExist(name())) {
+ QString errorMessage;
+- if (isPartiallyExpandedEntityValueTooLarge(&errorMessage)) {
+- // The entity at entityName is entityValue.size() characters
+- // long in its unexpanded form, and was mentioned timesReferenced times,
+- // resulting in a string that would be greater than 1024 characters.
++ if (isExpandedEntityValueTooLarge(&errorMessage)) {
+ reportParseError(errorMessage);
+ return false;
+ }
+--
+1.7
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..31115115993
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,448 @@
+# Maintainer: Felix Schindler
+# Contributor: Andrea Scarpino <andrea@archlinux.org>
+#
+# This package is maintained at https://github.com/ftalbrecht/aur/
+# in the qt51 branch
+
+pkgbase=qt51
+pkgname=('qt51-base'
+ 'qt51-declarative'
+ 'qt51-doc'
+ 'qt51-graphicaleffects'
+ 'qt51-imageformats'
+ 'qt51-jsbackend'
+ 'qt51-multimedia'
+ 'qt51-quick1'
+ 'qt51-quickcontrols'
+ 'qt51-script'
+ 'qt51-sensors'
+ 'qt51-serialport'
+ 'qt51-svg'
+ 'qt51-tools'
+ 'qt51-translations'
+ 'qt51-webkit'
+ 'qt51-x11extras'
+ 'qt51-xmlpatterns')
+pkgver=5.1.1
+pkgrel=2
+arch=('i686' 'x86_64')
+url='http://qt-project.org/'
+license=('GPL3' 'LGPL' 'FDL' 'custom')
+makedepends=('libxcb' 'xcb-proto' 'xcb-util' 'xcb-util-image' 'xcb-util-wm' 'xcb-util-keysyms'
+ 'mesa' 'at-spi2-core' 'alsa-lib' 'gstreamer0.10-base-plugins' 'libmng'
+ 'libjpeg-turbo' 'cups' 'libpulse' 'hicolor-icon-theme' 'desktop-file-utils'
+ 'postgresql-libs' 'libmariadbclient' 'sqlite' 'unixodbc' 'libfbclient'
+ 'python2' 'ruby' 'gperf' 'libxslt' 'libxcomposite' 'fontconfig'
+ 'openal' 'gtk2' 'libxkbcommon')
+groups=('qt51')
+_pkgfqn="qt-everywhere-opensource-src-${pkgver}"
+source=("http://download.qt-project.org/official_releases/qt/5.1/${pkgver}/single/${_pkgfqn}.tar.xz"
+ 'assistant-qt51.desktop' 'designer-qt51.desktop' 'linguist-qt51.desktop' 'qdbusviewer-qt51.desktop'
+ 'use-python2.patch'
+ 'bison3.patch' 'CVE-2013-4549.patch' 'libmng2.patch'
+ 'qt51.PATH')
+md5sums=('697b7b8768ef8895e168366ab6b44760'
+ 'd6fd35a4858c2519385d13c04985a947'
+ 'bc63cf356e5cbe40ca542ffc1c5fe4ab'
+ '4ce959cbe138df8589e81537ac40f37f'
+ '9019f5c97c91c9b29a50b55f3e33c40a'
+ '92831f79144d5cb8121915423ba47575'
+ '6b162cd2bc104f0ae83ca039401be7bf'
+ 'e59ba552e12408dcc9486cdbb1f233e3'
+ '478647fa057d190a7d789cf78995167b'
+ '28f4755e54ba1df5a89d60a73f6d1a9e')
+
+prepare() {
+ cd ${_pkgfqn}
+
+ sed -i "s|-O2|${CXXFLAGS}|" qtbase/mkspecs/common/{g++,gcc}-base.conf
+ sed -i "/^QMAKE_LFLAGS_RPATH/s| -Wl,-rpath,||g" qtbase/mkspecs/common/gcc-base-unix.conf
+ sed -i "/^QMAKE_LFLAGS\s/s|+=|+= ${LDFLAGS}|g" qtbase/mkspecs/common/gcc-base.conf
+
+ # Use python2 for Python 2.x
+ patch -p1 -i "${srcdir}"/use-python2.patch
+ sed -i -e "s|#![ ]*/usr/bin/python$|#!/usr/bin/python2|" \
+ -e "s|#![ ]*/usr/bin/env python$|#!/usr/bin/env python2|" \
+ $(find . -name '*.py')
+
+ # Fix build with bison 3.x
+ cd qtwebkit
+ patch -p1 -i "${srcdir}"/bison3.patch
+
+ cd ../qtbase
+ patch -p1 -i "${srcdir}"/CVE-2013-4549.patch
+
+ cd ../qtimageformats
+ patch -p1 -i "${srcdir}"/libmng2.patch
+}
+
+build() {
+ cd ${_pkgfqn}
+
+ export QTDIR="${srcdir}"/${_pkgfqn}
+ export LD_LIBRARY_PATH="${QTDIR}"/qtbase/lib:"${QTDIR}"/qttools/lib:"${LD_LIBRARY_PATH}"
+ export QT_PLUGIN_PATH="${QTDIR}"/qtbase/plugins
+
+ PYTHON=/usr/bin/python2 ./configure -confirm-license -opensource \
+ -prefix /opt/$pkgbase \
+ -plugin-sql-{psql,mysql,sqlite,odbc,ibase} \
+ -system-sqlite \
+ -openssl-linked \
+ -nomake examples \
+ -no-rpath \
+ -optimized-qmake \
+ -dbus-linked \
+ -reduce-relocations
+
+ make
+
+ # Fix paths
+ find "${QTDIR}" -name Makefile -exec sed -i "s|${pkgdir}/opt/$pkgbase/bin/qdoc|${QTDIR}/qtbase/bin/qdoc|g" {} +
+ find "${QTDIR}" -name Makefile.qmake-docs -exec sed -i "s|${pkgdir}/opt/$pkgbase/bin/qdoc|${QTDIR}/qtbase/bin/qdoc|g" {} +
+ find "${QTDIR}" -name Makefile -exec sed -i "s|${pkgdir}/opt/$pkgbase/bin/qhelpgenerator|${QTDIR}/qttools/bin/qhelpgenerator|g" {} +
+ find "${QTDIR}" -name Makefile.qmake-docs -exec sed -i "s|${pkgdir}/opt/$pkgbase/bin/qhelpgenerator|${QTDIR}/qttools/bin/qhelpgenerator|g" {} +
+ find "${QTDIR}" -name Makefile -exec sed -i "s|/opt/$pkgbase/bin/qdoc|${QTDIR}/qtbase/bin/qdoc|g" {} +
+ find "${QTDIR}" -name Makefile.qmake-docs -exec sed -i "s|/opt/$pkgbase/bin/qdoc|${QTDIR}/qtbase/bin/qdoc|g" {} +
+ find "${QTDIR}" -name Makefile -exec sed -i "s|/opt/$pkgbase/bin/qhelpgenerator|${QTDIR}/qttools/bin/qhelpgenerator|g" {} +
+ find "${QTDIR}" -name Makefile.qmake-docs -exec sed -i "s|/opt/$pkgbase/bin/qhelpgenerator|${QTDIR}/qttools/bin/qhelpgenerator|g" {} +
+ sed -i "s|${pkgdir}/opt/$pkgbase/bin/qhelpgenerator|${QTDIR}/qttools/bin/qhelpgenerator|g" qtwebkit/Source/Makefile.api
+ sed -i "s|/opt/$pkgbase/bin/qhelpgenerator|${QTDIR}/qttools/bin/qhelpgenerator|g" qtwebkit/Source/Makefile.api
+
+ make docs
+}
+
+package_qt51-base() {
+ pkgdesc='A cross-platform application and UI framework (5.1.x)'
+ depends=('libjpeg-turbo' 'xcb-util-keysyms' 'libgl' 'dbus' 'fontconfig' 'systemd'
+ 'xcb-util-wm' 'libxrender' 'libxi' 'sqlite' 'libpng' 'xcb-util-image'
+ 'icu' 'qtchooser' 'libxkbcommon')
+ optdepends=('postgresql-libs: PostgreSQL driver'
+ 'libmariadbclient: MariaDB driver'
+ 'unixodbc: ODBC driver'
+ 'libfbclient: Firebird/iBase driver')
+ # conflicts=('qt')
+ options=('staticlibs') #libQt5PlatformSupport builds static only
+
+ cd ${_pkgfqn}/qtbase
+ make INSTALL_ROOT="${pkgdir}" install
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+
+ # Fix wrong path in prl files
+ find "${pkgdir}/opt/$pkgbase/lib" -type f -name '*.prl' \
+ -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' {} \;
+
+ # Fix wrong qmake path in pri file
+ sed -i "s|${srcdir}/${_pkgfqn}/qtbase|/usr|" \
+ "${pkgdir}"/opt/$pkgbase/mkspecs/modules/qt_lib_bootstrap.pri
+
+ # Useful symlinks
+ install -d "${pkgdir}"/opt/$pkgbase/bin
+ for b in "${pkgdir}"/opt/$pkgbase/bin/*; do
+ ln -s /opt/$pkgbase/bin/$(basename $b) "${pkgdir}"/opt/$pkgbase/bin/$(basename $b)-qt5
+ done
+
+ # install PATH file
+ install -m644 "${srcdir}/$pkgbase.PATH" "${pkgdir}/opt/$pkgbase.PATH"
+}
+
+package_qt51-declarative() {
+ pkgdesc='A cross-platform application and UI framework (QtQml, QtQuick) (5.1.x)'
+ depends=('qt51-jsbackend' 'qt51-xmlpatterns')
+ # conflicts=('qt')
+
+ cd ${_pkgfqn}/qtdeclarative
+ make INSTALL_ROOT="${pkgdir}" install
+
+ # Fix wrong path in prl files
+ find "${pkgdir}/opt/$pkgbase/lib" -type f -name '*.prl' \
+ -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' {} \;
+
+ # Useful symlinks
+ install -d "${pkgdir}"/opt/$pkgbase/bin
+ for b in "${pkgdir}"/opt/$pkgbase/bin/*; do
+ ln -s "${pkgdir}"/opt/$pkgbase/bin/$(basename $b) "${pkgdir}"/opt/$pkgbase/bin/$(basename $b)-qt5
+ done
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
+
+package_qt51-doc() {
+ pkgdesc='A cross-platform application and UI framework (Documentation) (5.1.x)'
+ depends=('qt51-base')
+ # arch=('any')
+ # conflicts=('qt-doc')
+ # replaces=('qt-doc')
+ # provides=('qt-doc')
+ options=('docs' '!emptydirs')
+ groups=()
+
+ cd ${_pkgfqn}
+ make INSTALL_ROOT="${pkgdir}" install_docs
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
+
+package_qt51-jsbackend() {
+ pkgdesc='A cross-platform application and UI framework (QtV8) (5.1.x)'
+ depends=('qt51-base')
+
+ cd ${_pkgfqn}/qtjsbackend
+ make INSTALL_ROOT="${pkgdir}" install
+
+ # Fix wrong path in prl files
+ find "${pkgdir}/opt/$pkgbase/lib" -type f -name '*.prl' \
+ -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' {} \;
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
+
+package_qt51-xmlpatterns() {
+ pkgdesc='A cross-platform application and UI framework (QtXmlPatterns) (5.1.x)'
+ depends=('qt51-base')
+ # conflicts=('qt')
+
+ cd ${_pkgfqn}/qtxmlpatterns
+ make INSTALL_ROOT="${pkgdir}" install
+
+ # Fix wrong path in prl files
+ find "${pkgdir}/opt/$pkgbase/lib" -type f -name '*.prl' \
+ -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' {} \;
+
+ # Useful symlinks
+ install -d "${pkgdir}"/opt/$pkgbase/bin
+ for b in "${pkgdir}"/opt/$pkgbase/bin/*; do
+ ln -s "${pkgdir}"/opt/$pkgbase/bin/$(basename $b) "${pkgdir}"/opt/$pkgbase/bin/$(basename $b)-qt5
+ done
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
+
+package_qt51-translations() {
+ pkgdesc='A cross-platform application and UI framework (Translations) (5.1.x)'
+ depends=('qt51-base')
+ # conflicts=('qt')
+
+ cd ${_pkgfqn}/qttranslations
+ make INSTALL_ROOT="${pkgdir}" install
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
+
+package_qt51-multimedia() {
+ pkgdesc='A cross-platform application and UI framework (QtMultimedia) (5.1.x)'
+ depends=('qt51-declarative' 'libpulse' 'gstreamer0.10-base' 'openal')
+ # conflicts=('qt')
+
+ cd ${_pkgfqn}/qtmultimedia
+ make INSTALL_ROOT="${pkgdir}" install
+
+ # Fix wrong path in prl files
+ find "${pkgdir}/opt/$pkgbase/lib" -type f -name '*.prl' \
+ -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' {} \;
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
+
+package_qt51-graphicaleffects() {
+ pkgdesc='A cross-platform application and UI framework (QtGraphicalEffects) (5.1.x)'
+ depends=('qt51-declarative')
+
+ cd ${_pkgfqn}/qtgraphicaleffects
+ make INSTALL_ROOT="${pkgdir}" install
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
+
+package_qt51-imageformats() {
+ pkgdesc='A cross-platform application and UI framework (Images plugins) (5.1.x)'
+ depends=('qt51-base' 'libtiff' 'libmng')
+ # conflicts=('qt')
+
+ cd ${_pkgfqn}/qtimageformats
+ make INSTALL_ROOT="${pkgdir}" install
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
+
+package_qt51-quick1() {
+ pkgdesc='A cross-platform application and UI framework (QtDeclarative) (5.1.x)'
+ depends=('qt51-webkit' 'qt51-script')
+ # conflicts=('qt')
+
+ cd ${_pkgfqn}/qtquick1
+ make INSTALL_ROOT="${pkgdir}" install
+
+ # Fix wrong path in prl files
+ find "${pkgdir}"/opt/$pkgbase/lib -type f -name '*.prl' \
+ -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' {} \;
+
+ # Useful symlinks
+ install -d "${pkgdir}"/opt/$pkgbase/bin
+ for b in "${pkgdir}"/opt/$pkgbase/bin/*; do
+ ln -s "${pkgdir}"/opt/$pkgbase/bin/$(basename $b) "${pkgdir}"/opt/$pkgbase/bin/$(basename $b)-qt5
+ done
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
+
+package_qt51-quickcontrols() {
+ pkgdesc='A cross-platform application and UI framework (QtQuick) (5.1.x)'
+ depends=('qt51-declarative')
+
+ cd ${_pkgfqn}/qtquickcontrols
+ make INSTALL_ROOT="${pkgdir}" install
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
+
+package_qt51-script() {
+ pkgdesc='A cross-platform application and UI framework (QtScript) (5.1.x)'
+ depends=('qt51-base')
+ # conflicts=('qt')
+
+ cd ${_pkgfqn}/qtscript
+ make INSTALL_ROOT="${pkgdir}" install
+
+ # Fix wrong path in prl files
+ find "${pkgdir}"/opt/$pkgbase/lib -type f -name '*.prl' \
+ -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' {} \;
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
+
+package_qt51-sensors() {
+ pkgdesc='A cross-platform application and UI framework (QtSensors) (5.1.x)'
+ depends=('qt51-declarative')
+
+ cd ${_pkgfqn}/qtsensors
+ make INSTALL_ROOT="${pkgdir}" install
+
+ # Fix wrong path in prl files
+ find "${pkgdir}"/opt/$pkgbase/lib -type f -name '*.prl' \
+ -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' {} \;
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
+
+package_qt51-serialport() {
+ pkgdesc='A cross-platform application and UI framework (QtSerialPort) (5.1.x)'
+ depends=('qt51-base')
+
+ cd ${_pkgfqn}/qtserialport
+ make INSTALL_ROOT="${pkgdir}" install
+
+ # Fix wrong path in prl files
+ find "${pkgdir}"/opt/$pkgbase/lib -type f -name '*.prl' \
+ -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' {} \;
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
+
+package_qt51-svg() {
+ pkgdesc='A cross-platform application and UI framework (QtSvg) (5.1.x)'
+ depends=('qt51-base')
+ # conflicts=('qt')
+
+ cd ${_pkgfqn}/qtsvg
+ make INSTALL_ROOT="${pkgdir}" install
+
+ # Fix wrong path in prl files
+ find "${pkgdir}"/opt/$pkgbase/lib -type f -name '*.prl' \
+ -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' {} \;
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
+
+package_qt51-tools() {
+ pkgdesc='A cross-platform application and UI framework (Development Tools, QtHelp) (5.1.x)'
+ depends=('qt51-webkit' 'desktop-file-utils' 'qt51-translations' 'hicolor-icon-theme'
+ 'xdg-utils')
+ optdepends=('qt51-doc: documentation')
+ install='qt5-tools.install'
+ # conflicts=('qt')
+ options=('staticlibs') # libQt5UiTools builds as static only$
+
+ cd ${_pkgfqn}/qttools
+ make INSTALL_ROOT="${pkgdir}" install
+
+ # install missing icons and desktop files
+ for icon in src/linguist/linguist/images/icons/linguist-*-32.png ; do
+ size=$(echo $(basename ${icon}) | cut -d- -f2)
+ install -p -D -m644 ${icon} \
+ "${pkgdir}/usr/share/icons/hicolor/${size}x${size}/apps/linguist-${pkgbase}.png"
+ done
+
+ install -D -m644 src/assistant/assistant/images/assistant.png \
+ "${pkgdir}/usr/share/icons/hicolor/32x32/apps/assistant-${pkgbase}.png"
+ install -D -m644 src/assistant/assistant/images/assistant-128.png \
+ "${pkgdir}/usr/share/icons/hicolor/128x128/apps/assistant-${pkgbase}.png"
+ install -D -m644 src/designer/src/designer/images/designer.png \
+ "${pkgdir}/usr/share/icons/hicolor/128x128/apps/designer-${pkgbase}.png"
+ install -D -m644 src/qdbus/qdbusviewer/images/qdbusviewer.png \
+ "${pkgdir}/usr/share/icons/hicolor/32x32/apps/qdbusviewer-${pkgbase}.png"
+ install -D -m644 src/qdbus/qdbusviewer/images/qdbusviewer-128.png \
+ "${pkgdir}/usr/share/icons/hicolor/128x128/apps/qdbusviewer-${pkgbase}.png"
+ install -d "${pkgdir}/usr/share/applications"
+ install -m644 "${srcdir}"/{linguist,designer,assistant,qdbusviewer}-${pkgbase}.desktop \
+ "${pkgdir}/usr/share/applications/"
+
+ # Fix wrong path in prl files
+ find "${pkgdir}/opt/$pkgbase/lib" -type f -name '*.prl' \
+ -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' {} \;
+
+ # Useful symlinks
+ install -d "${pkgdir}"/opt/$pkgbase/bin
+ for b in "${pkgdir}"/opt/$pkgbase/bin/*; do
+ ln -s "${pkgdir}"/opt/$pkgbase/bin/$(basename $b) "${pkgdir}"/opt/$pkgbase/bin/$(basename $b)-qt5
+ done
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
+
+package_qt51-webkit() {
+ pkgdesc='A cross-platform application and UI framework (QtWebKit) (5.1.x)'
+ depends=('qt51-declarative' 'gstreamer0.10-base' 'libxslt' 'libxcomposite' 'qt51-sensors')
+ license=('GPL3' 'LGPL' 'FDL')
+
+ cd ${_pkgfqn}/qtwebkit
+ make INSTALL_ROOT="${pkgdir}" install
+
+ # Fix wrong path in prl files
+ find "${pkgdir}"/opt/$pkgbase/lib -type f -name '*.prl' \
+ -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' {} \;
+
+ # Fix wrong path in pc file
+ perl -pi -e "s, -L${srcdir}/?\S+,,g" "${pkgdir}"/opt/$pkgbase/lib/pkgconfig/Qt5WebKit.pc
+}
+
+package_qt51-x11extras() {
+ pkgdesc='A cross-platform application and UI framework (QtX11Extras) (5.1.x)'
+ depends=('qt51-base')
+
+ cd ${_pkgfqn}/qtx11extras
+ make INSTALL_ROOT="${pkgdir}" install
+
+ # Fix wrong path in prl files
+ find "${pkgdir}"/opt/$pkgbase/lib -type f -name '*.prl' \
+ -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' {} \;
+
+ install -D -m644 LGPL_EXCEPTION.txt \
+ "${pkgdir}"/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
+}
diff --git a/assistant-qt51.desktop b/assistant-qt51.desktop
new file mode 100644
index 00000000000..b7eb3f7f6d9
--- /dev/null
+++ b/assistant-qt51.desktop
@@ -0,0 +1,8 @@
+[Desktop Entry]
+Name=Qt Assistant (5.1.1-6)
+Comment=Shows Qt documentation and examples
+Exec=/opt/qt51/bin/assistant
+Icon=assistant-qt51
+Terminal=false
+Type=Application
+Categories=Qt;Development;Documentation;
diff --git a/bison3.patch b/bison3.patch
new file mode 100644
index 00000000000..4070c88e861
--- /dev/null
+++ b/bison3.patch
@@ -0,0 +1,38 @@
+From 60ba8bd5b3575d0c7740571fbb4e681b21a49a82 Mon Sep 17 00:00:00 2001
+From: Allan Sandfeld Jensen <allan.jensen@digia.com>
+Date: Fri, 16 Aug 2013 18:27:07 +0200
+Subject: [PATCH] ANGLE doesn't build with bison 3.0
+
+https://bugs.webkit.org/show_bug.cgi?id=119798
+
+Reviewed by Antti Koivisto.
+
+Make glslang.y compatible with bison 3.0
+by using %lex-param to set YYLEX_PARAM.
+
+* src/compiler/glslang.y:
+
+git-svn-id: http://svn.webkit.org/repository/webkit/trunk@154109 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+Task-number: QTBUG-32913
+Change-Id: I15505d31f0588c4d558b73befdb9d2358e29c1a3
+Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
+---
+ Source/ThirdParty/ANGLE/src/compiler/glslang.y | 1 +
+ 1 files changed, 1 insertions(+), 0 deletions(-)
+
+diff --git a/Source/ThirdParty/ANGLE/src/compiler/glslang.y b/Source/ThirdParty/ANGLE/src/compiler/glslang.y
+index 3cad335..b41e95a 100644
+--- a/Source/ThirdParty/ANGLE/src/compiler/glslang.y
++++ b/Source/ThirdParty/ANGLE/src/compiler/glslang.y
+@@ -47,6 +47,7 @@ WHICH GENERATES THE GLSL ES PARSER (glslang_tab.cpp AND glslang_tab.h).
+ %expect 1 /* One shift reduce conflict because of if | else */
+ %pure-parser
+ %parse-param {TParseContext* context}
++%lex-param {YYLEX_PARAM}
+
+ %union {
+ struct {
+--
+1.7.1
+
diff --git a/designer-qt51.desktop b/designer-qt51.desktop
new file mode 100644
index 00000000000..82d51fccc8f
--- /dev/null
+++ b/designer-qt51.desktop
@@ -0,0 +1,10 @@
+[Desktop Entry]
+Name=Qt Designer (5.1.1)
+GenericName=Interface Designer
+Comment=Design GUIs for Qt applications
+Exec=/opt/qt51/bin/designer
+Icon=designer-qt51
+MimeType=application/x-designer;
+Terminal=false
+Type=Application
+Categories=Qt;Development;
diff --git a/libmng2.patch b/libmng2.patch
new file mode 100644
index 00000000000..0e23f60f7ce
--- /dev/null
+++ b/libmng2.patch
@@ -0,0 +1,34 @@
+From 9ae386653c321c8ddc10fad5ea88f32ebb3d3ffe Mon Sep 17 00:00:00 2001
+From: aavit <eirik.aavitsland@digia.com>
+Date: Fri, 22 Nov 2013 15:04:23 +0100
+Subject: [PATCH] Recognize newer libmng versions in config test
+
+libmng 2.0.x has been released and is compatible and usable, but since
+it no longer provides a VERSION_MAJOR macro, the config test would fail.
+
+Task-number: QTBUG-34894
+Change-Id: I106aa258de0851af01d1bb016c2971dd8e30fd24
+Reviewed-by: Liang Qi <liang.qi@digia.com>
+---
+ config.tests/libmng/libmng.cpp | 2 ++
+ 1 files changed, 2 insertions(+), 0 deletions(-)
+
+diff --git a/config.tests/libmng/libmng.cpp b/config.tests/libmng/libmng.cpp
+index 9def33e..fc3e693 100644
+--- a/config.tests/libmng/libmng.cpp
++++ b/config.tests/libmng/libmng.cpp
+@@ -46,9 +46,11 @@ int main(int, char **)
+ mng_handle hMNG;
+ mng_cleanup(&hMNG);
+
++#if defined(MNG_VERSION_MAJOR)
+ #if MNG_VERSION_MAJOR < 1 || (MNG_VERSION_MAJOR == 1 && MNG_VERSION_MINOR == 0 && MNG_VERSION_RELEASE < 9)
+ #error System libmng version is less than 1.0.9; using built-in version instead.
+ #endif
++#endif
+
+ return 0;
+ }
+--
+1.7.1
+
diff --git a/linguist-qt51.desktop b/linguist-qt51.desktop
new file mode 100644
index 00000000000..168328bf7aa
--- /dev/null
+++ b/linguist-qt51.desktop
@@ -0,0 +1,9 @@
+[Desktop Entry]
+Name=Qt Linguist (5.1.1)
+Comment=Add translations to Qt applications
+Exec=/opt/qt5/linguist
+Icon=linguist-qt51
+MimeType=text/vnd.trolltech.linguist;application/x-linguist;
+Terminal=false
+Type=Application
+Categories=Qt;Development;
diff --git a/qdbusviewer-qt51.desktop b/qdbusviewer-qt51.desktop
new file mode 100644
index 00000000000..d8fffb676cc
--- /dev/null
+++ b/qdbusviewer-qt51.desktop
@@ -0,0 +1,9 @@
+[Desktop Entry]
+Name=Qt QDbusViewer (5.1.1)
+GenericName=D-Bus Debugger
+Comment=Debug D-Bus applications
+Exec=/opt/qt51/bin/qdbusviewer
+Icon=qdbusviewer-qt51
+Terminal=false
+Type=Application
+Categories=Qt;Development;Debugger;
diff --git a/qt5-tools.install b/qt5-tools.install
new file mode 100644
index 00000000000..5495fb1b5d2
--- /dev/null
+++ b/qt5-tools.install
@@ -0,0 +1,12 @@
+post_install() {
+ xdg-icon-resource forceupdate --theme hicolor &> /dev/null
+ update-desktop-database -q
+}
+
+post_upgrade() {
+ post_install
+}
+
+post_remove() {
+ post_install
+}
diff --git a/qt51.PATH b/qt51.PATH
new file mode 100644
index 00000000000..40661a51a82
--- /dev/null
+++ b/qt51.PATH
@@ -0,0 +1,4 @@
+export PATH=/opt/qt51/bin:$PATH
+export LD_LIBRARY_PATH=/opt/qt51/lib:$LD_LIBRARY_PATH
+export PKG_CONFIG_PATH=/opt/qt51/lib/pkgconfig:$PKG_CONFIG_PATH
+
diff --git a/use-python2.patch b/use-python2.patch
new file mode 100644
index 00000000000..57487b99689
--- /dev/null
+++ b/use-python2.patch
@@ -0,0 +1,118 @@
+--- qt-everywhere-opensource-src-5.0.0/qtjsbackend/src/v8/v8.pri~ 2013-01-11 06:50:55.241495644 +0000
++++ qt-everywhere-opensource-src-5.0.0/qtjsbackend/src/v8/v8.pri 2013-01-11 06:51:29.987894356 +0000
+@@ -303,7 +303,7 @@
+ V8_EXPERIMENTAL_LIBRARY_FILES = \
+ $$V8SRC/proxy.js \
+
+-v8_js2c.commands = python $$V8DIR/tools/js2c.py $$V8_GENERATED_SOURCES_DIR/libraries.cpp CORE off
++v8_js2c.commands = python2 $$V8DIR/tools/js2c.py $$V8_GENERATED_SOURCES_DIR/libraries.cpp CORE off
+ v8_js2c.commands += $$V8SRC/macros.py ${QMAKE_FILE_IN}
+ v8_js2c.output = $$V8_GENERATED_SOURCES_DIR/libraries.cpp
+ v8_js2c.input = V8_LIBRARY_FILES
+@@ -314,7 +314,7 @@
+ v8_js2c.name = generating[v8] ${QMAKE_FILE_IN}
+ silent:v8_js2c.commands = @echo generating[v8] ${QMAKE_FILE_IN} && $$v8_js2c.commands
+
+-v8_js2c_experimental.commands = python $$V8DIR/tools/js2c.py $$V8_GENERATED_SOURCES_DIR/experimental-libraries.cpp EXPERIMENTAL off
++v8_js2c_experimental.commands = python2 $$V8DIR/tools/js2c.py $$V8_GENERATED_SOURCES_DIR/experimental-libraries.cpp EXPERIMENTAL off
+ v8_js2c_experimental.commands += $$V8SRC/macros.py ${QMAKE_FILE_IN}
+ v8_js2c_experimental.output = $$V8_GENERATED_SOURCES_DIR/experimental-libraries.cpp
+ v8_js2c_experimental.input = V8_EXPERIMENTAL_LIBRARY_FILES
+--- qt-everywhere-opensource-src-5.0.0/qtwebkit/Source/JavaScriptCore/DerivedSources.pri~ 2013-01-09 11:29:16.452266719 +0000
++++ qt-everywhere-opensource-src-5.0.0/qtwebkit/Source/JavaScriptCore/DerivedSources.pri 2013-01-09 11:30:18.188538725 +0000
+@@ -85,14 +85,14 @@
+ retgen.output = RegExpJitTables.h
+ retgen.script = $$PWD/create_regex_tables
+ retgen.input = retgen.script
+-retgen.commands = python $$retgen.script > ${QMAKE_FILE_OUT}
++retgen.commands = python2 $$retgen.script > ${QMAKE_FILE_OUT}
+ GENERATORS += retgen
+
+ #GENERATOR: "KeywordLookup.h": decision tree used by the lexer
+ klgen.output = KeywordLookup.h
+ klgen.script = $$PWD/KeywordLookupGenerator.py
+ klgen.input = KEYWORDLUT_FILES
+-klgen.commands = python $$klgen.script ${QMAKE_FILE_NAME} > ${QMAKE_FILE_OUT}
++klgen.commands = python2 $$klgen.script ${QMAKE_FILE_NAME} > ${QMAKE_FILE_OUT}
+ GENERATORS += klgen
+
+ EXTRACTOR_BINARY = LLIntOffsetsExtractor$$BIN_EXTENSION
+@@ -117,7 +117,7 @@
+ disassembler.input = DISASSEMBLER_FILES
+ disassembler.script = $$PWD/disassembler/udis86/itab.py
+ disassembler.depends = $$DISASSEMBLER_DEPENDENCY
+- disassembler.commands = python $$disassembler.script ${QMAKE_FILE_NAME} --outputDir ${QMAKE_FUNC_FILE_OUT_PATH}
++ disassembler.commands = python2 $$disassembler.script ${QMAKE_FILE_NAME} --outputDir ${QMAKE_FUNC_FILE_OUT_PATH}
+ disassembler.CONFIG += no_link
+ GENERATORS += disassembler
+ }
+--- qt-everywhere-opensource-src-5.0.0/qtwebkit/Source/WebCore/DerivedSources.pri~ 2013-01-09 11:46:01.165612894 +0000
++++ qt-everywhere-opensource-src-5.0.0/qtwebkit/Source/WebCore/DerivedSources.pri 2013-01-09 11:46:27.465404725 +0000
+@@ -779,7 +779,7 @@
+ inspectorValidate.output = InspectorProtocolVersion.h
+ inspectorValidate.input = INSPECTOR_JSON
+ inspectorValidate.script = $$PWD/inspector/generate-inspector-protocol-version
+-inspectorValidate.commands = python $$inspectorValidate.script -o ${QMAKE_FILE_OUT} ${QMAKE_FILE_IN}
++inspectorValidate.commands = python2 $$inspectorValidate.script -o ${QMAKE_FILE_OUT} ${QMAKE_FILE_IN}
+ inspectorValidate.depends = $$PWD/inspector/generate-inspector-protocol-version
+ inspectorValidate.add_output_to_sources = false
+ GENERATORS += inspectorValidate
+@@ -787,7 +787,7 @@
+ inspectorJSON.output = InspectorFrontend.cpp InspectorBackendDispatcher.cpp InspectorTypeBuilder.cpp
+ inspectorJSON.input = INSPECTOR_JSON
+ inspectorJSON.script = $$PWD/inspector/CodeGeneratorInspector.py
+-inspectorJSON.commands = python $$inspectorJSON.script $$PWD/inspector/Inspector.json --output_h_dir ${QMAKE_FUNC_FILE_OUT_PATH} --output_cpp_dir ${QMAKE_FUNC_FILE_OUT_PATH}
++inspectorJSON.commands = python2 $$inspectorJSON.script $$PWD/inspector/Inspector.json --output_h_dir ${QMAKE_FUNC_FILE_OUT_PATH} --output_cpp_dir ${QMAKE_FUNC_FILE_OUT_PATH}
+ inspectorJSON.depends = $$inspectorJSON.script
+ GENERATORS += inspectorJSON
+
+@@ -908,7 +908,7 @@
+ entities.output = HTMLEntityTable.cpp
+ entities.input = HTML_ENTITIES
+ entities.script = $$PWD/html/parser/create-html-entity-table
+-entities.commands = python $$entities.script -o ${QMAKE_FILE_OUT} $$HTML_ENTITIES
++entities.commands = python2 $$entities.script -o ${QMAKE_FILE_OUT} $$HTML_ENTITIES
+ entities.clean = ${QMAKE_FILE_OUT}
+ entities.depends = $$PWD/html/parser/create-html-entity-table
+ GENERATORS += entities
+--- qt-everywhere-opensource-src-5.0.1/qtwebkit/Source/WebKit2/DerivedSources.pri~ 2013-02-10 13:48:49.800319915 +0000
++++ qt-everywhere-opensource-src-5.0.1/qtwebkit/Source/WebKit2/DerivedSources.pri 2013-02-10 13:49:09.966867900 +0000
+@@ -120,14 +120,14 @@
+ $$PWD/Scripts/webkit2/model.py \
+ $$PWD/Scripts/webkit2/parser.py
+
+-message_header_generator.commands = $${PYTHON} $${SOURCE_DIR}/WebKit2/Scripts/generate-messages-header.py ${QMAKE_FILE_IN} > ${QMAKE_FILE_OUT}
++message_header_generator.commands = python2 $${SOURCE_DIR}/WebKit2/Scripts/generate-messages-header.py ${QMAKE_FILE_IN} > ${QMAKE_FILE_OUT}
+ message_header_generator.input = MESSAGE_RECEIVERS
+ message_header_generator.depends = $$SCRIPTS
+ message_header_generator.output_function = message_header_generator_output
+ message_header_generator.add_output_to_sources = false
+ GENERATORS += message_header_generator
+
+-message_receiver_generator.commands = $${PYTHON} $${SOURCE_DIR}/WebKit2/Scripts/generate-message-receiver.py ${QMAKE_FILE_IN} > ${QMAKE_FILE_OUT}
++message_receiver_generator.commands = python2 $${SOURCE_DIR}/WebKit2/Scripts/generate-message-receiver.py ${QMAKE_FILE_IN} > ${QMAKE_FILE_OUT}
+ message_receiver_generator.input = MESSAGE_RECEIVERS
+ message_receiver_generator.depends = $$SCRIPTS
+ message_receiver_generator.output_function = message_receiver_generator_output
+--- qt-everywhere-opensource-src-5.0.2/qtwebkit/Tools/qmake/mkspecs/features/configure.prf~ 2013-04-11 08:05:15.149214600 +0000
++++ qt-everywhere-opensource-src-5.0.2/qtwebkit/Tools/qmake/mkspecs/features/configure.prf 2013-04-11 08:05:28.829105110 +0000
+@@ -116,7 +116,7 @@
+ production_build:blackberry {
+ addReasonForSkippingBuild("Build not supported on BB10 yet.")
+ }
+- requiredPrograms = gperf python perl bison ruby flex
++ requiredPrograms = gperf python2 perl bison ruby flex
+ for(program, requiredPrograms): \
+ !programExistsInPath($$program): \
+ addReasonForSkippingBuild("Missing $$program from PATH")
+--- qt-everywhere-opensource-src-5.1.0/qtjsbackend/src/3rdparty/v8/src/d8.gyp.old 2013-07-03 19:22:34.536705691 +0000
++++ qt-everywhere-opensource-src-5.1.0/qtjsbackend/src/3rdparty/v8/src/d8.gyp 2013-07-03 19:22:25.606770334 +0000
+@@ -99,7 +99,7 @@
+ '<(SHARED_INTERMEDIATE_DIR)/d8-js.cc',
+ ],
+ 'action': [
+- 'python',
++ 'python2',
+ '../tools/js2c.py',
+ '<@(_outputs)',
+ 'D8',