summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorPatrick J Volkerding <volkerdi@slackware.com>2020-02-15 02:42:28 +0000
committerEric Hameleers <alien@slackware.com>2020-02-15 08:59:47 +0100
commit7cde3ca9e7c5de666cc607e737f984a52f94e021 (patch)
tree9625b6c02d0dad1e8cc40f9713b2c1d4919d011a /source
parentbea4af160dc640549e07144b9a0dddf09b569861 (diff)
downloadcurrent-7cde3ca9e7c5de666cc607e737f984a52f94e021.tar.gz
Sat Feb 15 02:42:28 UTC 202020200215024228
a/kernel-generic-5.4.20-x86_64-1.txz: Upgraded. a/kernel-huge-5.4.20-x86_64-1.txz: Upgraded. a/kernel-modules-5.4.20-x86_64-1.txz: Upgraded. a/shadow-4.8.1-x86_64-3.txz: Rebuilt. a/util-linux-2.35.1-x86_64-3.txz: Rebuilt. d/kernel-headers-5.4.20-x86-1.txz: Upgraded. k/kernel-source-5.4.20-noarch-1.txz: Upgraded. l/ConsoleKit2-1.2.1-x86_64-2.txz: Rebuilt. l/dconf-editor-3.34.4-x86_64-1.txz: Upgraded. l/libxkbcommon-0.10.0-x86_64-1.txz: Added. l/openal-soft-1.19.1-x86_64-1.txz: Added. l/qt5-5.13.2-x86_64-1.txz: Added. Thanks to alienBOB. n/openssh-8.2p1-x86_64-1.txz: Upgraded. Potentially incompatible changes: * ssh(1), sshd(8): the removal of "ssh-rsa" from the accepted CASignatureAlgorithms list. * ssh(1), sshd(8): this release removes diffie-hellman-group14-sha1 from the default key exchange proposal for both the client and server. * ssh-keygen(1): the command-line options related to the generation and screening of safe prime numbers used by the diffie-hellman-group-exchange-* key exchange algorithms have changed. Most options have been folded under the -O flag. * sshd(8): the sshd listener process title visible to ps(1) has changed to include information about the number of connections that are currently attempting authentication and the limits configured by MaxStartups. x/mesa-19.3.4-x86_64-2.txz: Rebuilt. Reverted "[PATCH] swr: Fix GCC 4.9 checks." which makes X fail to start with an illegal instruction on some hardware. isolinux/initrd.img: Rebuilt. kernels/*: Upgraded. testing/packages/PAM/ConsoleKit2-1.2.1-x86_64-2_pam.txz: Rebuilt. Rebuilt with --disable-libcgmanager to fix setting limits on PAM. Thanks to gattocarlo. testing/packages/PAM/openssh-8.2p1-x86_64-1_pam.txz: Upgraded. testing/packages/PAM/shadow-4.8.1-x86_64-3_pam.txz: Rebuilt. Moved some of the /etc/pam.d/ file to the util-linux package where they more properly belong. testing/packages/PAM/util-linux-2.35.1-x86_64-3_pam.txz: Rebuilt. Added some /etc/pam.d/ files previously in the shadow package. Changed /etc/pam.d/{chfn,chsh} and made chfn/chsh setuid root to fix them. Added /etc/pam.d/{runuser,runuser-l}. usb-and-pxe-installers/usbboot.img: Rebuilt.
Diffstat (limited to 'source')
-rw-r--r--source/a/shadow/doinst.sh27
-rw-r--r--source/a/shadow/pam.d/chfn4
-rw-r--r--source/a/shadow/pam.d/chsh4
-rwxr-xr-xsource/a/shadow/shadow.SlackBuild2
-rw-r--r--source/a/util-linux/doinst.sh6
-rw-r--r--source/a/util-linux/pam.d/chfn6
-rw-r--r--source/a/util-linux/pam.d/chsh6
-rw-r--r--source/a/util-linux/pam.d/login (renamed from source/a/shadow/pam.d/login)0
-rw-r--r--source/a/util-linux/pam.d/runuser5
-rw-r--r--source/a/util-linux/pam.d/runuser-l4
-rw-r--r--source/a/util-linux/pam.d/su (renamed from source/a/shadow/pam.d/su)0
-rw-r--r--source/a/util-linux/pam.d/su-l (renamed from source/a/shadow/pam.d/su-l)0
-rwxr-xr-xsource/a/util-linux/util-linux.SlackBuild21
-rw-r--r--source/k/kernel-configs/config-generic-5.4.20 (renamed from source/k/kernel-configs/config-generic-5.4.19)2
-rw-r--r--source/k/kernel-configs/config-generic-5.4.20.x64 (renamed from source/k/kernel-configs/config-generic-5.4.19.x64)2
-rw-r--r--source/k/kernel-configs/config-generic-smp-5.4.20-smp (renamed from source/k/kernel-configs/config-generic-smp-5.4.19-smp)2
-rw-r--r--source/k/kernel-configs/config-huge-5.4.20 (renamed from source/k/kernel-configs/config-huge-5.4.19)2
-rw-r--r--source/k/kernel-configs/config-huge-5.4.20.x64 (renamed from source/k/kernel-configs/config-huge-5.4.19.x64)2
-rw-r--r--source/k/kernel-configs/config-huge-smp-5.4.20-smp (renamed from source/k/kernel-configs/config-huge-smp-5.4.19-smp)2
-rwxr-xr-xsource/l/ConsoleKit2/ConsoleKit2.SlackBuild5
-rwxr-xr-xsource/l/libxkbcommon/libxkbcommon.SlackBuild130
-rw-r--r--source/l/libxkbcommon/slack-desc19
-rw-r--r--source/l/openal-soft/.deps1
-rw-r--r--source/l/openal-soft/.url2
-rw-r--r--source/l/openal-soft/doinst.sh13
-rwxr-xr-xsource/l/openal-soft/openal-soft.SlackBuild137
-rw-r--r--source/l/openal-soft/slack-desc19
-rw-r--r--source/l/qt5/.deps2
-rw-r--r--source/l/qt5/.url1
-rw-r--r--source/l/qt5/doinst.sh9
-rw-r--r--source/l/qt5/patches/platformplugin-install-path-fix.patch15
-rw-r--r--source/l/qt5/patches/qt5.alsa.patch11
-rw-r--r--source/l/qt5/patches/qt5.cr206850.patch43
-rw-r--r--source/l/qt5/patches/qt5.cve-2020-0569.patch29
-rw-r--r--source/l/qt5/patches/qt5.cve-2020-0570.patch48
-rw-r--r--source/l/qt5/patches/qt5.delayed_highlight.patch72
-rw-r--r--source/l/qt5/patches/qt5.glibc224.patch33
-rw-r--r--source/l/qt5/patches/qt5.mysql.h.diff11
-rw-r--r--source/l/qt5/patches/qt5.private-includes.patch53
-rw-r--r--source/l/qt5/patches/qt5.pulseaudio.diff12
-rw-r--r--source/l/qt5/patches/qt5.qlockfile-deadlock.patch116
-rw-r--r--source/l/qt5/patches/qt5.qt5uitoolsconfig.patch17
-rw-r--r--source/l/qt5/patches/qt5.qtbase_cmake_isystem_includes.patch14
-rw-r--r--source/l/qt5/patches/qt5.qtbug-49061.patch80
-rw-r--r--source/l/qt5/patches/qt5.qtbug-49452.patch58
-rw-r--r--source/l/qt5/patches/qt5.qtbug-51621.patch39
-rw-r--r--source/l/qt5/patches/qt5.qtbug-51648.patch88
-rw-r--r--source/l/qt5/patches/qt5.qtbug-51649.patch159
-rw-r--r--source/l/qt5/patches/qt5.qtbug-51676.patch126
-rw-r--r--source/l/qt5/patches/qt5.qtbug-51890.patch82
-rw-r--r--source/l/qt5/patches/qt5.qtbug-51927.patch185
-rw-r--r--source/l/qt5/patches/qt5.qtbug-53237.patch90
-rw-r--r--source/l/qt5/patches/qt5.qtbug-55583.patch41
-rw-r--r--source/l/qt5/patches/qt5.qtbug-60558.patch32
-rw-r--r--source/l/qt5/patches/qt5.qtbug-61140.patch101
-rw-r--r--source/l/qt5/patches/qt5.qtbug-66103.patch172
-rw-r--r--source/l/qt5/patches/qt5.qtbug-69310.patch37
-rw-r--r--source/l/qt5/patches/qt5.qtbug-76255.patch35
-rw-r--r--source/l/qt5/patches/qt5.qtbug-77037.patch89
-rw-r--r--source/l/qt5/patches/qt5.qtbug-77364.patch13
-rw-r--r--source/l/qt5/patches/qt5.webengine_gcc8.patch26
-rw-r--r--source/l/qt5/patches/qt5.whandle.patch24
-rw-r--r--source/l/qt5/patches/qtbase-qxcbwindow.patch97
-rw-r--r--source/l/qt5/patches/qtbase-zlib-compression.patch41
-rw-r--r--source/l/qt5/profile.d/qt5.csh17
-rw-r--r--source/l/qt5/profile.d/qt5.sh17
-rwxr-xr-xsource/l/qt5/qt5.SlackBuild341
-rw-r--r--source/l/qt5/slack-desc19
-rw-r--r--source/n/openssh/openssh.tcp_wrappers.diff31
-rw-r--r--source/n/openssh/openssh.url1
-rw-r--r--source/x/mesa/0001-swr-Fix-GCC-4.9-checks.patch58
-rwxr-xr-xsource/x/mesa/mesa.SlackBuild11
72 files changed, 2970 insertions, 49 deletions
diff --git a/source/a/shadow/doinst.sh b/source/a/shadow/doinst.sh
index ce3e8116..98c8a92c 100644
--- a/source/a/shadow/doinst.sh
+++ b/source/a/shadow/doinst.sh
@@ -10,17 +10,20 @@ config() {
# Otherwise, we leave the .new copy for the admin to consider...
}
-# First, check for PAM:
-if [ -r etc/pam.d/login.new ]; then
- # If there's an existing /etc/login.defs that contains an obsolete option
- # intended for a non-pam system, rename it to back it up and allow the
- # pam-enabled login.defs to be installed automatically:
- if grep -q "^LASTLOG_ENAB" etc/login.defs 1> /dev/null 2> /dev/null ; then
- mv etc/login.defs etc/login.defs.non-pam.backup
- fi
-else # Same thing, but in reverse for a non-pam system:
- if ! grep -q "^LASTLOG_ENAB" etc/login.defs 1> /dev/null 2> /dev/null ; then
- mv etc/login.defs etc/login.defs.pam.backup
+# See if we need to backup an existing login.defs:
+if [ -r etc/login.defs ]; then
+ # First, check for PAM:
+ if [ -r etc/pam.d/login.new ]; then
+ # If there's an existing /etc/login.defs that contains an obsolete option
+ # intended for a non-pam system, rename it to back it up and allow the
+ # pam-enabled login.defs to be installed automatically:
+ if grep -q "^LASTLOG_ENAB" etc/login.defs 1> /dev/null 2> /dev/null ; then
+ mv etc/login.defs etc/login.defs.non-pam.backup
+ fi
+ else # Same thing, but in reverse for a non-pam system:
+ if ! grep -q "^LASTLOG_ENAB" etc/login.defs 1> /dev/null 2> /dev/null ; then
+ mv etc/login.defs etc/login.defs.pam.backup
+ fi
fi
fi
@@ -31,7 +34,7 @@ rm -f var/log/faillog.new
if [ -r etc/login.access.new ]; then
config etc/login.access.new
fi
-for configfile in chage.new chfn.new chgpasswd.new chpasswd.new chsh.new groupadd.new groupdel.new groupmems.new groupmod.new login.new newusers.new other.new passwd.new postlogin.new su-l.new su.new system-auth.new useradd.new userdel.new usermod.new ; do
+for configfile in chage.new chgpasswd.new chpasswd.new groupadd.new groupdel.new groupmems.new groupmod.new newusers.new other.new passwd.new postlogin.new system-auth.new useradd.new userdel.new usermod.new ; do
if [ -r etc/pam.d/$configfile ]; then
config etc/pam.d/$configfile
fi
diff --git a/source/a/shadow/pam.d/chfn b/source/a/shadow/pam.d/chfn
deleted file mode 100644
index 8f49f5cc..00000000
--- a/source/a/shadow/pam.d/chfn
+++ /dev/null
@@ -1,4 +0,0 @@
-#%PAM-1.0
-auth sufficient pam_rootok.so
-account required pam_permit.so
-password include system-auth
diff --git a/source/a/shadow/pam.d/chsh b/source/a/shadow/pam.d/chsh
deleted file mode 100644
index 8f49f5cc..00000000
--- a/source/a/shadow/pam.d/chsh
+++ /dev/null
@@ -1,4 +0,0 @@
-#%PAM-1.0
-auth sufficient pam_rootok.so
-account required pam_permit.so
-password include system-auth
diff --git a/source/a/shadow/shadow.SlackBuild b/source/a/shadow/shadow.SlackBuild
index bc22d5e8..1cd486be 100755
--- a/source/a/shadow/shadow.SlackBuild
+++ b/source/a/shadow/shadow.SlackBuild
@@ -24,7 +24,7 @@ cd $(dirname $0) ; CWD=$(pwd)
PKGNAM=shadow
VERSION=${VERSION:-$(echo $PKGNAM-*.tar.xz | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
-BUILD=${BUILD:-2}
+BUILD=${BUILD:-3}
# Automatically determine the architecture we're building on:
if [ -z "$ARCH" ]; then
diff --git a/source/a/util-linux/doinst.sh b/source/a/util-linux/doinst.sh
index da24e743..8277c0e6 100644
--- a/source/a/util-linux/doinst.sh
+++ b/source/a/util-linux/doinst.sh
@@ -22,6 +22,12 @@ config etc/rc.d/rc.serial.new
config etc/rc.d/rc.setterm.new
config etc/serial.conf.new
+for configfile in chfn.new chsh.new login.new runuser.new runuser-l.new su.new su-l.new ; do
+ if [ -r etc/pam.d/$configfile ]; then
+ config etc/pam.d/$configfile
+ fi
+done
+
if [ -r etc/default/su.new ]; then
config etc/default/su.new
fi
diff --git a/source/a/util-linux/pam.d/chfn b/source/a/util-linux/pam.d/chfn
new file mode 100644
index 00000000..2dbc0aaf
--- /dev/null
+++ b/source/a/util-linux/pam.d/chfn
@@ -0,0 +1,6 @@
+#%PAM-1.0
+auth sufficient pam_rootok.so
+auth include system-auth
+account include system-auth
+password include system-auth
+session include system-auth
diff --git a/source/a/util-linux/pam.d/chsh b/source/a/util-linux/pam.d/chsh
new file mode 100644
index 00000000..2dbc0aaf
--- /dev/null
+++ b/source/a/util-linux/pam.d/chsh
@@ -0,0 +1,6 @@
+#%PAM-1.0
+auth sufficient pam_rootok.so
+auth include system-auth
+account include system-auth
+password include system-auth
+session include system-auth
diff --git a/source/a/shadow/pam.d/login b/source/a/util-linux/pam.d/login
index eb312199..eb312199 100644
--- a/source/a/shadow/pam.d/login
+++ b/source/a/util-linux/pam.d/login
diff --git a/source/a/util-linux/pam.d/runuser b/source/a/util-linux/pam.d/runuser
new file mode 100644
index 00000000..37f0e84e
--- /dev/null
+++ b/source/a/util-linux/pam.d/runuser
@@ -0,0 +1,5 @@
+#%PAM-1.0
+auth sufficient pam_rootok.so
+session optional pam_keyinit.so revoke
+session required pam_limits.so
+session required pam_unix.so
diff --git a/source/a/util-linux/pam.d/runuser-l b/source/a/util-linux/pam.d/runuser-l
new file mode 100644
index 00000000..fa1e4d83
--- /dev/null
+++ b/source/a/util-linux/pam.d/runuser-l
@@ -0,0 +1,4 @@
+#%PAM-1.0
+auth include runuser
+session optional pam_keyinit.so force revoke
+session include runuser
diff --git a/source/a/shadow/pam.d/su b/source/a/util-linux/pam.d/su
index c7c81487..c7c81487 100644
--- a/source/a/shadow/pam.d/su
+++ b/source/a/util-linux/pam.d/su
diff --git a/source/a/shadow/pam.d/su-l b/source/a/util-linux/pam.d/su-l
index 656a139a..656a139a 100644
--- a/source/a/shadow/pam.d/su-l
+++ b/source/a/util-linux/pam.d/su-l
diff --git a/source/a/util-linux/util-linux.SlackBuild b/source/a/util-linux/util-linux.SlackBuild
index 1d101d46..2f0688be 100755
--- a/source/a/util-linux/util-linux.SlackBuild
+++ b/source/a/util-linux/util-linux.SlackBuild
@@ -26,7 +26,7 @@ cd $(dirname $0) ; CWD=$(pwd)
PKGNAM=util-linux
VERSION=${VERSION:-$(echo util-linux*.tar.xz | cut -d - -f 3 | rev | cut -f 3- -d . | rev)}
-BUILD=${BUILD:-2}
+BUILD=${BUILD:-3}
ADJTIMEXVERS=1.29
SETSERIALVERS=2.17
@@ -90,6 +90,17 @@ if [ -L /lib${LIBDIRSUFFIX}/libpam.so.? ]; then
cp -a $CWD/su.default $PKG/etc/default/su.new
chown root:root $PKG/etc/default/su.new
chmod 644 $PKG/etc/default/su.new
+ # Add /etc/pam.d config files:
+ rm -rf $PKG/etc/pam.d
+ mkdir -p $PKG/etc/pam.d
+ for file in $CWD/pam.d/* ; do
+ cp -a ${file} $PKG/etc/pam.d/
+ done
+ # Ensure correct perms/ownership on files in /etc/pam.d/:
+ chown root:root $PKG/etc/pam.d/*
+ chmod 644 $PKG/etc/pam.d/*
+ # Don't clobber existing config files:
+ find $PKG/etc/pam.d -type f -exec mv {} {}.new \;
else
LOGIN_OPTIONS="--disable-login"
fi
@@ -150,6 +161,14 @@ CFLAGS="$SLKCFLAGS" \
make $NUMJOBS || make || exit 1
make install $NUMJOBS DESTDIR=$PKG || exit 1
+# These need to be setuid root to work properly (only built for PAM):
+if [ -r $PKG/usr/bin/chfn ]; then
+ chmod 4711 $PKG/usr/bin/chfn
+fi
+if [ -r $PKG/usr/bin/chsh ]; then
+ chmod 4711 $PKG/usr/bin/chsh
+fi
+
# Build python3 bindings for libmount:
make clean
CFLAGS="$SLKCFLAGS" \
diff --git a/source/k/kernel-configs/config-generic-5.4.19 b/source/k/kernel-configs/config-generic-5.4.20
index 7e8bedaa..9788a749 100644
--- a/source/k/kernel-configs/config-generic-5.4.19
+++ b/source/k/kernel-configs/config-generic-5.4.20
@@ -1,6 +1,6 @@
#
# Automatically generated file; DO NOT EDIT.
-# Linux/x86 5.4.19 Kernel Configuration
+# Linux/x86 5.4.20 Kernel Configuration
#
#
diff --git a/source/k/kernel-configs/config-generic-5.4.19.x64 b/source/k/kernel-configs/config-generic-5.4.20.x64
index 6937b960..9657ba25 100644
--- a/source/k/kernel-configs/config-generic-5.4.19.x64
+++ b/source/k/kernel-configs/config-generic-5.4.20.x64
@@ -1,6 +1,6 @@
#
# Automatically generated file; DO NOT EDIT.
-# Linux/x86 5.4.19 Kernel Configuration
+# Linux/x86 5.4.20 Kernel Configuration
#
#
diff --git a/source/k/kernel-configs/config-generic-smp-5.4.19-smp b/source/k/kernel-configs/config-generic-smp-5.4.20-smp
index 256b5074..47a7ab59 100644
--- a/source/k/kernel-configs/config-generic-smp-5.4.19-smp
+++ b/source/k/kernel-configs/config-generic-smp-5.4.20-smp
@@ -1,6 +1,6 @@
#
# Automatically generated file; DO NOT EDIT.
-# Linux/x86 5.4.19 Kernel Configuration
+# Linux/x86 5.4.20 Kernel Configuration
#
#
diff --git a/source/k/kernel-configs/config-huge-5.4.19 b/source/k/kernel-configs/config-huge-5.4.20
index e92aca88..9d7ea412 100644
--- a/source/k/kernel-configs/config-huge-5.4.19
+++ b/source/k/kernel-configs/config-huge-5.4.20
@@ -1,6 +1,6 @@
#
# Automatically generated file; DO NOT EDIT.
-# Linux/x86 5.4.19 Kernel Configuration
+# Linux/x86 5.4.20 Kernel Configuration
#
#
diff --git a/source/k/kernel-configs/config-huge-5.4.19.x64 b/source/k/kernel-configs/config-huge-5.4.20.x64
index 696055d0..fd4b55d2 100644
--- a/source/k/kernel-configs/config-huge-5.4.19.x64
+++ b/source/k/kernel-configs/config-huge-5.4.20.x64
@@ -1,6 +1,6 @@
#
# Automatically generated file; DO NOT EDIT.
-# Linux/x86 5.4.19 Kernel Configuration
+# Linux/x86 5.4.20 Kernel Configuration
#
#
diff --git a/source/k/kernel-configs/config-huge-smp-5.4.19-smp b/source/k/kernel-configs/config-huge-smp-5.4.20-smp
index 23068ddd..17eb2ec1 100644
--- a/source/k/kernel-configs/config-huge-smp-5.4.19-smp
+++ b/source/k/kernel-configs/config-huge-smp-5.4.20-smp
@@ -1,6 +1,6 @@
#
# Automatically generated file; DO NOT EDIT.
-# Linux/x86 5.4.19 Kernel Configuration
+# Linux/x86 5.4.20 Kernel Configuration
#
#
diff --git a/source/l/ConsoleKit2/ConsoleKit2.SlackBuild b/source/l/ConsoleKit2/ConsoleKit2.SlackBuild
index ccea00b2..73a13404 100755
--- a/source/l/ConsoleKit2/ConsoleKit2.SlackBuild
+++ b/source/l/ConsoleKit2/ConsoleKit2.SlackBuild
@@ -28,7 +28,7 @@ cd $(dirname $0) ; CWD=$(pwd)
PKGNAM=ConsoleKit2
VERSION=${VERSION:-1.2.1}
-BUILD=${BUILD:-1}
+BUILD=${BUILD:-2}
# Maximum storage quota for XDG_RUNTIME_DIR:
XDG_RUNTIME_QUOTA=${XDG_RUNTIME_QUOTA:-size=100M}
@@ -103,7 +103,7 @@ find . \
# Choose correct options depending on whether PAM is installed:
if [ -L /lib${LIBDIRSUFFIX}/libpam.so.? ]; then
- PAM_OPTIONS="--enable-pam-module=yes"
+ PAM_OPTIONS="--enable-pam-module=yes --disable-libcgmanager"
unset SHADOW_OPTIONS
else
unset PAM_OPTIONS
@@ -125,6 +125,7 @@ CXXFLAGS="$SLKCFLAGS" \
$PAM_OPTIONS \
$SHADOW_OPTIONS \
--enable-udev-acl \
+ --enable-polkit \
--disable-static \
--build=$TARGET || exit 1
diff --git a/source/l/libxkbcommon/libxkbcommon.SlackBuild b/source/l/libxkbcommon/libxkbcommon.SlackBuild
new file mode 100755
index 00000000..4d0b56d5
--- /dev/null
+++ b/source/l/libxkbcommon/libxkbcommon.SlackBuild
@@ -0,0 +1,130 @@
+#!/bin/bash
+
+# Copyright 2020 Patrick J. Volkerding, Sebeka, Minnesota, USA
+# Copyright 2015, 2017, 2018, 2019 Eric Hameleers, Eindhoven, NL
+# All rights reserved.
+#
+# Redistribution and use of this script, with or without modification, is
+# permitted provided that the following conditions are met:
+#
+# 1. Redistributions of this script must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+cd $(dirname $0) ; CWD=$(pwd)
+
+PKGNAM=libxkbcommon
+VERSION=${VERSION:-$(echo $PKGNAM-*.tar.?z | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
+BUILD=${BUILD:-1}
+
+# Automatically determine the architecture we're building on:
+if [ -z "$ARCH" ]; then
+ case "$(uname -m)" in
+ i?86) ARCH=i586 ;;
+ arm*) readelf /usr/bin/file -A | egrep -q "Tag_CPU.*[4,5]" && ARCH=arm || ARCH=armv7hl ;;
+ # Unless $ARCH is already set, use uname -m for all other archs:
+ *) ARCH=$(uname -m) ;;
+ esac
+ export ARCH
+fi
+
+# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
+# the name of the created package would be, and then exit. This information
+# could be useful to other scripts.
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PKGNAM-$VERSION-$ARCH-$BUILD.txz"
+ exit 0
+fi
+
+NUMJOBS=${NUMJOBS:-" -j$(expr $(nproc) + 1) "}
+
+if [ "$ARCH" = "i586" ]; then
+ SLKCFLAGS="-O2 -march=i586 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "s390" ]; then
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
+elif [ "$ARCH" = "armv7hl" ]; then
+ SLKCFLAGS="-O3 -march=armv7-a -mfpu=vfpv3-d16"
+ LIBDIRSUFFIX=""
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+fi
+
+TMP=${TMP:-/tmp}
+PKG=$TMP/package-$PKGNAM
+
+rm -rf $PKG
+mkdir -p $TMP $PKG
+
+cd $TMP
+rm -rf $PKGNAM-$VERSION
+tar xvf $CWD/$PKGNAM-$VERSION.tar.?z || exit 1
+cd $PKGNAM-$VERSION || exit 1
+
+chown -R root:root .
+find . \
+ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
+ -exec chmod 755 {} \+ -o \
+ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
+ -exec chmod 644 {} \+
+
+# Configure, build, and install:
+export CFLAGS="$SLKCFLAGS"
+export CXXFLAGS="$SLKCFLAGS"
+mkdir meson-build
+cd meson-build
+meson setup \
+ --prefix=/usr \
+ --libdir=lib${LIBDIRSUFFIX} \
+ --libexecdir=/usr/libexec \
+ --bindir=/usr/bin \
+ --sbindir=/usr/sbin \
+ --includedir=/usr/include \
+ --datadir=/usr/share \
+ --mandir=/usr/man \
+ --sysconfdir=/etc \
+ --localstatedir=/var \
+ --buildtype=release \
+ -Denable-wayland=false \
+ .. || exit 1
+ "${NINJA:=ninja}" $NUMJOBS || exit 1
+ DESTDIR=$PKG $NINJA install || exit 1
+cd ..
+
+# Strip binaries:
+find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+
+# Add a documentation directory:
+mkdir -p $PKG/usr/doc/${PKGNAM}-$VERSION
+cp -a \
+ LICENSE* NEWS* PACKAGING* README* \
+ $PKG/usr/doc/${PKGNAM}-$VERSION
+
+# Relocate other documentation:
+mv $PKG/usr/share/doc/libxkbcommon/* $PKG/usr/doc/${PKGNAM}-$VERSION
+rm -rf $PKG/usr/share/doc
+rmdir $PKG/usr/share 2> /dev/null
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+
+cd $PKG
+/sbin/makepkg -l y -c n $TMP/$PKGNAM-$VERSION-$ARCH-$BUILD.txz
diff --git a/source/l/libxkbcommon/slack-desc b/source/l/libxkbcommon/slack-desc
new file mode 100644
index 00000000..4f826909
--- /dev/null
+++ b/source/l/libxkbcommon/slack-desc
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description.
+# Line up the first '|' above the ':' following the base package name, and
+# the '|' on the right side marks the last column you can put a character in.
+# You must make exactly 11 lines for the formatting to be correct. It's also
+# customary to leave one space after the ':' except on otherwise blank lines.
+
+ |-----handy-ruler------------------------------------------------------|
+libxkbcommon: libxkbcommon (keyboard description library)
+libxkbcommon:
+libxkbcommon: xkbcommon is a library to handle keyboard descriptions, including
+libxkbcommon: loading them from disk, parsing them and handling their state. It's
+libxkbcommon: mainly meant for client toolkits, window systems, and other system
+libxkbcommon: applications; currently that includes Wayland, kmscon, GTK+, Qt,
+libxkbcommon: Clutter, and more. It is also used by some XCB applications for proper
+libxkbcommon: keyboard support.
+libxkbcommon:
+libxkbcommon: Home page: http://xkbcommon.org/
+libxkbcommon:
diff --git a/source/l/openal-soft/.deps b/source/l/openal-soft/.deps
new file mode 100644
index 00000000..b787fd16
--- /dev/null
+++ b/source/l/openal-soft/.deps
@@ -0,0 +1 @@
+SDL_sound
diff --git a/source/l/openal-soft/.url b/source/l/openal-soft/.url
new file mode 100644
index 00000000..51a72d92
--- /dev/null
+++ b/source/l/openal-soft/.url
@@ -0,0 +1,2 @@
+http://kcat.strangesoft.net/openal-releases/openal-soft-1.19.1.tar.bz2
+
diff --git a/source/l/openal-soft/doinst.sh b/source/l/openal-soft/doinst.sh
new file mode 100644
index 00000000..5a935205
--- /dev/null
+++ b/source/l/openal-soft/doinst.sh
@@ -0,0 +1,13 @@
+#!/bin/sh
+config() {
+ NEW="$1"
+ OLD="`dirname $NEW`/`basename $NEW .new`"
+ # If there's no config file by that name, mv it over:
+ if [ ! -r $OLD ]; then
+ mv $NEW $OLD
+ elif [ "`cat $OLD | md5sum`" = "`cat $NEW | md5sum`" ]; then # toss the redundant copy
+ rm $NEW
+ fi
+ # Otherwise, we leave the .new copy for the admin to consider...
+}
+config etc/openal/alsoft.conf.new
diff --git a/source/l/openal-soft/openal-soft.SlackBuild b/source/l/openal-soft/openal-soft.SlackBuild
new file mode 100755
index 00000000..20107ed4
--- /dev/null
+++ b/source/l/openal-soft/openal-soft.SlackBuild
@@ -0,0 +1,137 @@
+#!/bin/bash
+
+# Copyright 2014, 2020 Patrick J. Volkerding, Sebeka, MN, USA
+# Copyright 2012, 2013, 2014, 2015, 2017, 2018, 2019 Eric Hameleers, Eindhoven, NL
+# All rights reserved.
+#
+# Redistribution and use of this script, with or without modification, is
+# permitted provided that the following conditions are met:
+#
+# 1. Redistributions of this script must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+cd $(dirname $0) ; CWD=$(pwd)
+
+PKGNAM=openal-soft
+VERSION=${VERSION:-$(echo $PKGNAM-*.tar.?z | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
+BUILD=${BUILD:-1}
+
+# Automatically determine the architecture we're building on:
+if [ -z "$ARCH" ]; then
+ case "$(uname -m)" in
+ i?86) ARCH=i586 ;;
+ arm*) readelf /usr/bin/file -A | egrep -q "Tag_CPU.*[4,5]" && ARCH=arm || ARCH=armv7hl ;;
+ # Unless $ARCH is already set, use uname -m for all other archs:
+ *) ARCH=$(uname -m) ;;
+ esac
+ export ARCH
+fi
+
+# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
+# the name of the created package would be, and then exit. This information
+# could be useful to other scripts.
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PKGNAM-$VERSION-$ARCH-$BUILD.txz"
+ exit 0
+fi
+
+NUMJOBS=${NUMJOBS:-" -j$(expr $(nproc) + 1) "}
+
+if [ "$ARCH" = "i586" ]; then
+ SLKCFLAGS="-O2 -march=i586 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "s390" ]; then
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
+elif [ "$ARCH" = "armv7hl" ]; then
+ SLKCFLAGS="-O3 -march=armv7-a -mfpu=vfpv3-d16"
+ LIBDIRSUFFIX=""
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+fi
+
+TMP=${TMP:-/tmp}
+PKG=$TMP/package-$PKGNAM
+
+rm -rf $PKG
+mkdir -p $TMP $PKG
+
+cd $TMP
+rm -rf $PKGNAM-$VERSION
+tar xvf $CWD/$PKGNAM-$VERSION.tar.?z || exit 1
+cd $PKGNAM-$VERSION || exit 1
+
+chown -R root:root .
+find . \
+ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
+ -exec chmod 755 {} \+ -o \
+ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
+ -exec chmod 644 {} \+
+
+# Configure, build, and install:
+mkdir cmake-build
+cd cmake-build
+ cmake \
+ -DCMAKE_C_FLAGS="$SLKCFLAGS" \
+ -DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DLIB_SUFFIX="$LIBDIRSUFFIX" \
+ -DDOC_INSTALL_DIR="doc" \
+ -DMAN_INSTALL_DIR=/usr/man \
+ -DSYSCONF_INSTALL_DIR=/etc \
+ -DCMAKE_BUILD_TYPE=Release \
+ .. || exit 1
+ make $NUMJOBS || make || exit 1
+ make install DESTDIR=$PKG || exit 1
+cd ..
+
+# Don't ship .la files:
+rm -f $PKG/{,usr/}lib${LIBDIRSUFFIX}/*.la
+
+# Strip binaries:
+find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+
+# Add configuration file:
+mkdir -p $PKG/etc/openal
+cp -a alsoftrc.sample $PKG/etc/openal/alsoft.conf.new
+chown root:root $PKG/etc/openal/alsoft.conf.new
+chmod 644 $PKG/etc/openal/alsoft.conf.new
+
+# Add a documentation directory:
+mkdir -p $PKG/usr/doc/${PKGNAM}-$VERSION
+cp -a \
+ COPYING* ChangeLog READMEi* XCompile.txt docs/*.txt \
+ $PKG/usr/doc/${PKGNAM}-$VERSION
+
+# If there's a ChangeLog, installing at least part of the recent history
+# is useful, but don't let it get totally out of control:
+if [ -r ChangeLog ]; then
+ DOCSDIR=$(echo $PKG/usr/doc/${PKGNAM}-$VERSION)
+ cat ChangeLog | head -n 1000 > $DOCSDIR/ChangeLog
+ touch -r ChangeLog $DOCSDIR/ChangeLog
+fi
+
+mkdir -p $PKG/install
+zcat $CWD/doinst.sh.gz > $PKG/install/doinst.sh
+cat $CWD/slack-desc > $PKG/install/slack-desc
+
+cd $PKG
+/sbin/makepkg -l y -c n $TMP/$PKGNAM-$VERSION-$ARCH-$BUILD.txz
diff --git a/source/l/openal-soft/slack-desc b/source/l/openal-soft/slack-desc
new file mode 100644
index 00000000..4dd73679
--- /dev/null
+++ b/source/l/openal-soft/slack-desc
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description. Line
+# up the first '|' above the ':' following the base package name, and the '|'
+# on the right side marks the last column you can put a character in. You must
+# make exactly 11 lines for the formatting to be correct. It's also
+# customary to leave one space after the ':'.
+
+ |-----handy-ruler------------------------------------------------------|
+openal-soft: openal-soft (OpenAL 3D audio API)
+openal-soft:
+openal-soft: OpenAL Soft is an LGPL-licensed, cross-platform, implementation of the
+openal-soft: OpenAL 3D audio API. OpenAL Soft provides capabilities for playing
+openal-soft: audio in a virtual 3D environment. It also facilitates streaming
+openal-soft: audio, multi-channel buffers, and audio capture.
+openal-soft:
+openal-soft: Homepage: https://openal-soft.org
+openal-soft:
+openal-soft:
+openal-soft:
diff --git a/source/l/qt5/.deps b/source/l/qt5/.deps
new file mode 100644
index 00000000..d1eaacd0
--- /dev/null
+++ b/source/l/qt5/.deps
@@ -0,0 +1,2 @@
+OpenAL
+libxkbcommon
diff --git a/source/l/qt5/.url b/source/l/qt5/.url
new file mode 100644
index 00000000..cc9f30be
--- /dev/null
+++ b/source/l/qt5/.url
@@ -0,0 +1 @@
+https://download.qt.io/official_releases/qt/5.13/5.13.2/single/qt-everywhere-src-5.13.2.tar.xz
diff --git a/source/l/qt5/doinst.sh b/source/l/qt5/doinst.sh
new file mode 100644
index 00000000..3e5691a0
--- /dev/null
+++ b/source/l/qt5/doinst.sh
@@ -0,0 +1,9 @@
+if [ -x /usr/bin/update-desktop-database ]; then
+ /usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1
+fi
+
+if [ -e usr/share/icons/hicolor/icon-theme.cache ]; then
+ if [ -x /usr/bin/gtk-update-icon-cache ]; then
+ /usr/bin/gtk-update-icon-cache usr/share/icons/hicolor >/dev/null 2>&1
+ fi
+fi
diff --git a/source/l/qt5/patches/platformplugin-install-path-fix.patch b/source/l/qt5/patches/platformplugin-install-path-fix.patch
new file mode 100644
index 00000000..db9b33b9
--- /dev/null
+++ b/source/l/qt5/patches/platformplugin-install-path-fix.patch
@@ -0,0 +1,15 @@
+See https://bugs.webkit.org/show_bug.cgi?id=117077
+
+diff -Naur qt-everywhere-opensource-src-5.0.2.orig/qtwebkit/Source/WebKit/qt/examples/platformplugin/platformplugin.pro qt-everywhere-opensource-src-5.0.2/qtwebkit/Source/WebKit/qt/examples/platformplugin/platformplugin.pro
+--- qt-everywhere-opensource-src-5.0.2.orig/qtwebkit/Source/WebKit/qt/examples/platformplugin/platformplugin.pro 2013-04-09 00:11:38.000000000 +0000
++++ qt-everywhere-opensource-src-5.0.2/qtwebkit/Source/WebKit/qt/examples/platformplugin/platformplugin.pro 2013-05-31 01:18:29.157175082 +0000
+@@ -20,7 +20,8 @@
+ }
+ }
+
+-DESTDIR = $$[QT_INSTALL_PLUGINS]/webkit
++target.path = $$[QT_INSTALL_PLUGINS]/webkit
++INSTALLS += target
+
+ SOURCES += \
+ WebPlugin.cpp \
diff --git a/source/l/qt5/patches/qt5.alsa.patch b/source/l/qt5/patches/qt5.alsa.patch
new file mode 100644
index 00000000..892431b3
--- /dev/null
+++ b/source/l/qt5/patches/qt5.alsa.patch
@@ -0,0 +1,11 @@
+--- qt-everywhere-opensource-src-5.6.0/qtbase/config.tests/unix/alsa/alsatest.cpp.orig 2016-02-29 08:15:48.203031809 +0000
++++ qt-everywhere-opensource-src-5.6.0/qtbase/config.tests/unix/alsa/alsatest.cpp 2016-02-29 08:16:39.712811962 +0000
+@@ -32,7 +32,7 @@
+ ****************************************************************************/
+
+ #include <alsa/asoundlib.h>
+-#if(!(SND_LIB_MAJOR == 1 && SND_LIB_MINOR == 0 && SND_LIB_SUBMINOR >= 10))
++#if(!(SND_LIB_MAJOR == 1 && (SND_LIB_MINOR > 0 || SND_LIB_SUBMINOR >= 10)))
+ #error "Alsa version found too old, require >= 1.0.10"
+ #endif
+
diff --git a/source/l/qt5/patches/qt5.cr206850.patch b/source/l/qt5/patches/qt5.cr206850.patch
new file mode 100644
index 00000000..1fb71df1
--- /dev/null
+++ b/source/l/qt5/patches/qt5.cr206850.patch
@@ -0,0 +1,43 @@
+The latest MariaDB versions aren't caught properly by the checks in Qt, which
+may cause a regression to appear (regression, because it was already fixed in
+Qt by Dan Vratil): this manifests itself in Akonadi losing its connection to
+the database if running for long periods of time.
+
+Until this is fixed in Qt, you may want to apply this patch in your packages:
+
+https://codereview.qt-project.org/#/c/206850/
+
+From 64588c9bae92ef79f9ca5e87653ffb0962691d0d Mon Sep 17 00:00:00 2001
+From: Andy Shaw <andy.shaw@qt.io>
+Date: Wed, 27 Sep 2017 09:23:10 +0200
+Subject: [PATCH] Extend the MariaDB define check to cover the later versions too
+
+Change-Id: Ide89b4e07feb116bf152cbf3f5630d313e8ba0f1
+---
+ src/plugins/sqldrivers/mysql/qsql_mysql.cpp | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/plugins/sqldrivers/mysql/qsql_mysql.cpp b/src/plugins/sqldrivers/mysql/qsql_mysql.cpp
+index 6e428fb..b2d3e85 100644
+--- a/src/plugins/sqldrivers/mysql/qsql_mysql.cpp
++++ b/src/plugins/sqldrivers/mysql/qsql_mysql.cpp
+@@ -1159,14 +1159,14 @@ static void qLibraryInit()
+ # endif // MYSQL_VERSION_ID
+ #endif // Q_NO_MYSQL_EMBEDDED
+
+-#ifdef MARIADB_BASE_VERSION
++#if defined(MARIADB_BASE_VERSION) || defined(MARIADB_VERSION_ID)
+ qAddPostRoutine(mysql_server_end);
+ #endif
+ }
+
+ static void qLibraryEnd()
+ {
+-#if !defined(MARIADB_BASE_VERSION)
++#if !defined(MARIADB_BASE_VERSION) && !defined(MARIADB_VERSION_ID)
+ # if !defined(Q_NO_MYSQL_EMBEDDED)
+ # if MYSQL_VERSION_ID > 40000
+ # if (MYSQL_VERSION_ID >= 40110 && MYSQL_VERSION_ID < 50000) || MYSQL_VERSION_ID >= 50003
+--
+2.7.4
+
diff --git a/source/l/qt5/patches/qt5.cve-2020-0569.patch b/source/l/qt5/patches/qt5.cve-2020-0569.patch
new file mode 100644
index 00000000..fa0efdce
--- /dev/null
+++ b/source/l/qt5/patches/qt5.cve-2020-0569.patch
@@ -0,0 +1,29 @@
+From bf131e8d2181b3404f5293546ed390999f760404 Mon Sep 17 00:00:00 2001
+From: Olivier Goffart <ogoffart@woboq.com>
+Date: Fri, 8 Nov 2019 11:30:40 +0100
+Subject: Do not load plugin from the $PWD
+
+I see no reason why this would make sense to look for plugins in the current
+directory. And when there are plugins there, it may actually be wrong
+
+Change-Id: I5f5aa168021fedddafce90effde0d5762cd0c4c5
+Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
+---
+ src/corelib/plugin/qpluginloader.cpp | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/src/corelib/plugin/qpluginloader.cpp b/src/corelib/plugin/qpluginloader.cpp
+index cadff4f32b..c2443dbdda 100644
+--- a/src/corelib/plugin/qpluginloader.cpp
++++ b/src/corelib/plugin/qpluginloader.cpp
+@@ -305,7 +305,6 @@ static QString locatePlugin(const QString& fileName)
+ paths.append(fileName.left(slash)); // don't include the '/'
+ } else {
+ paths = QCoreApplication::libraryPaths();
+- paths.prepend(QStringLiteral(".")); // search in current dir first
+ }
+
+ for (const QString &path : qAsConst(paths)) {
+--
+cgit v1.2.1
+
diff --git a/source/l/qt5/patches/qt5.cve-2020-0570.patch b/source/l/qt5/patches/qt5.cve-2020-0570.patch
new file mode 100644
index 00000000..fa3eb331
--- /dev/null
+++ b/source/l/qt5/patches/qt5.cve-2020-0570.patch
@@ -0,0 +1,48 @@
+QLibrary/Unix: do not attempt to load a library relative to $PWD
+
+I added the code in commit 5219c37f7c98f37f078fee00fe8ca35d83ff4f5d to
+find libraries in a haswell/ subdir of the main path, but we only need
+to do that transformation if the library is contains at least one
+directory seprator. That is, if the user asks to load "lib/foo", then we
+should try "lib/haswell/foo" (often, the path prefix will be absolute).
+
+When the library name the user requested has no directory separators, we
+let dlopen() do the transformation for us. Testing on Linux confirms
+glibc does so:
+
+$ LD_DEBUG=libs /lib64/ld-linux-x86-64.so.2 --inhibit-cache ./qml -help |& grep Xcursor
+ 1972475: find library=libXcursor.so.1 [0]; searching
+ 1972475: trying file=/usr/lib64/haswell/avx512_1/libXcursor.so.1
+ 1972475: trying file=/usr/lib64/haswell/libXcursor.so.1
+ 1972475: trying file=/usr/lib64/libXcursor.so.1
+ 1972475: calling init: /usr/lib64/libXcursor.so.1
+ 1972475: calling fini: /usr/lib64/libXcursor.so.1 [0]
+
+Fixes: QTBUG-81272
+Change-Id: I596aec77785a4e4e84d5fffd15e89689bb91ffbb
+
+X-Git-Url: https://codereview.qt-project.org/gitweb?p=qt%2Fqtbase.git;a=blobdiff_plain;f=src%2Fcorelib%2Fplugin%2Fqlibrary_unix.cpp;h=135b82cd378b00abe231c2320866d88f8a71b25a;hp=f0de1010d7b7126d83c4365a31924fa080ec334d;hb=27d92ead3a5f3c145f16b96f95a43c5af136a36b;hpb=3b54009b13e9629b75827a59f8537451d25613a4
+
+diff --git a/src/corelib/plugin/qlibrary_unix.cpp b/src/corelib/plugin/qlibrary_unix.cpp
+index f0de1010d7b..135b82cd378 100644
+--- a/src/corelib/plugin/qlibrary_unix.cpp
++++ b/src/corelib/plugin/qlibrary_unix.cpp
+@@ -1,7 +1,7 @@
+ /****************************************************************************
+ **
+ ** Copyright (C) 2016 The Qt Company Ltd.
+-** Copyright (C) 2018 Intel Corporation
++** Copyright (C) 2020 Intel Corporation
+ ** Contact: https://www.qt.io/licensing/
+ **
+ ** This file is part of the QtCore module of the Qt Toolkit.
+@@ -218,6 +218,8 @@ bool QLibraryPrivate::load_sys()
+ for(int suffix = 0; retry && !pHnd && suffix < suffixes.size(); suffix++) {
+ if (!prefixes.at(prefix).isEmpty() && name.startsWith(prefixes.at(prefix)))
+ continue;
++ if (path.isEmpty() && prefixes.at(prefix).contains(QLatin1Char('/')))
++ continue;
+ if (!suffixes.at(suffix).isEmpty() && name.endsWith(suffixes.at(suffix)))
+ continue;
+ if (loadHints & QLibrary::LoadArchiveMemberHint) {
+
diff --git a/source/l/qt5/patches/qt5.delayed_highlight.patch b/source/l/qt5/patches/qt5.delayed_highlight.patch
new file mode 100644
index 00000000..201179bb
--- /dev/null
+++ b/source/l/qt5/patches/qt5.delayed_highlight.patch
@@ -0,0 +1,72 @@
+From f8f0f3eef1151c9377a5c76ccfa6432e930e1307 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?M=C3=A5rten=20Nordheim?= <marten.nordheim@qt.io>
+Date: Mon, 14 Jan 2019 10:37:42 +0100
+Subject: QSyntaxHighlighter: cancel delayed highlight if done manually
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+It was an implicit effect before which stopped working after
+dec7961709c90f6977d2447f7fa6c6625af41cb2. Reintroduce it as some
+projects used this side-effect as a way to abort the initial
+highlighting.
+
+Change-Id: I5340ee9882a242bc8b5f7f843f1cfe793a65d357
+Reviewed-by: J?drzej Nowacki <jedrzej.nowacki@qt.io>
+---
+ src/gui/text/qsyntaxhighlighter.cpp | 1 +
+ .../qsyntaxhighlighter/tst_qsyntaxhighlighter.cpp | 19 +++++++++++++++++++
+ 2 files changed, 20 insertions(+)
+
+diff --git a/src/gui/text/qsyntaxhighlighter.cpp b/src/gui/text/qsyntaxhighlighter.cpp
+index b09f8b565a..0e07b69868 100644
+--- a/src/gui/text/qsyntaxhighlighter.cpp
++++ b/src/gui/text/qsyntaxhighlighter.cpp
+@@ -376,6 +376,7 @@ void QSyntaxHighlighter::rehighlight()
+
+ QTextCursor cursor(d->doc);
+ d->rehighlight(cursor, QTextCursor::End);
++ d->rehighlightPending = false; // user manually did a full rehighlight
+ }
+
+ /*!
+diff --git a/tests/auto/gui/text/qsyntaxhighlighter/tst_qsyntaxhighlighter.cpp b/tests/auto/gui/text/qsyntaxhighlighter/tst_qsyntaxhighlighter.cpp
+index 9d6ce78b24..c683ecd424 100644
+--- a/tests/auto/gui/text/qsyntaxhighlighter/tst_qsyntaxhighlighter.cpp
++++ b/tests/auto/gui/text/qsyntaxhighlighter/tst_qsyntaxhighlighter.cpp
+@@ -82,6 +82,7 @@ private slots:
+ void preservePreeditArea();
+ void task108530();
+ void avoidUnnecessaryRehighlight();
++ void avoidUnnecessaryDelayedRehighlight();
+ void noContentsChangedDuringHighlight();
+ void rehighlight();
+ void rehighlightBlock();
+@@ -478,6 +479,24 @@ void tst_QSyntaxHighlighter::avoidUnnecessaryRehighlight()
+ QTRY_VERIFY(!hl->highlighted);
+ }
+
++void tst_QSyntaxHighlighter::avoidUnnecessaryDelayedRehighlight()
++{
++ // Having text in the document before creating the highlighter starts the delayed rehighlight
++ cursor.insertText("Hello World");
++
++ TestHighlighter *hl = new TestHighlighter(doc);
++ QVERIFY(!hl->highlighted);
++
++ hl->rehighlight();
++ QVERIFY(hl->highlighted);
++
++ hl->highlighted = false;
++ // Process events, including delayed rehighlight emission
++ QCoreApplication::processEvents();
++ // Should be cancelled and no extra rehighlight should be done
++ QVERIFY(!hl->highlighted);
++}
++
+ void tst_QSyntaxHighlighter::noContentsChangedDuringHighlight()
+ {
+ QVector<QTextLayout::FormatRange> formats;
+--
+cgit v1.2.1
+
diff --git a/source/l/qt5/patches/qt5.glibc224.patch b/source/l/qt5/patches/qt5.glibc224.patch
new file mode 100644
index 00000000..773781ac
--- /dev/null
+++ b/source/l/qt5/patches/qt5.glibc224.patch
@@ -0,0 +1,33 @@
+From b12ffcd411d4776f7120ccecb3be34344d930d2b Mon Sep 17 00:00:00 2001
+From: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
+Date: Tue, 9 Aug 2016 16:21:29 +0200
+Subject: Do not depend on Linux 4.5
+
+Avoid using MADV_FREE that was only recently added to Linux. It will fail when
+run on older Linux kernels.
+
+Change-Id: I9b0369fb31402f088b2327c12f70dd39f5e4c8c0
+Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
+---
+ chromium/third_party/WebKit/Source/wtf/PageAllocator.cpp | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/src/3rdparty/chromium/third_party/WebKit/Source/wtf/PageAllocator.cpp b/src/3rdparty/chromium/third_party/WebKit/Source/wtf/PageAllocator.cpp
+index 121b687..be7c3b9 100644
+--- a/src/3rdparty/chromium/third_party/WebKit/Source/wtf/PageAllocator.cpp
++++ b/src/3rdparty/chromium/third_party/WebKit/Source/wtf/PageAllocator.cpp
+@@ -39,6 +39,11 @@
+
+ #include <sys/mman.h>
+
++#if OS(LINUX) && defined(MADV_FREE)
++// Added in Linux 4.5, but we don't want to depend on 4.5 at runtime
++#undef MADV_FREE
++#endif
++
+ #ifndef MADV_FREE
+ #define MADV_FREE MADV_DONTNEED
+ #endif
+--
+cgit v1.0-4-g1e03
+
diff --git a/source/l/qt5/patches/qt5.mysql.h.diff b/source/l/qt5/patches/qt5.mysql.h.diff
new file mode 100644
index 00000000..f1cf11b9
--- /dev/null
+++ b/source/l/qt5/patches/qt5.mysql.h.diff
@@ -0,0 +1,11 @@
+--- qt-everywhere-opensource-src-5.9.0/qtbase/src/plugins/sqldrivers/mysql/qsql_mysql_p.h.orig 2017-05-26 14:43:31.000000000 +0200
++++ qt-everywhere-opensource-src-5.9.0/qtbase/src/plugins/sqldrivers/mysql/qsql_mysql_p.h 2017-06-17 22:11:34.211899826 +0200
+@@ -57,7 +57,7 @@
+ #include <QtCore/qt_windows.h>
+ #endif
+
+-#include <mysql.h>
++#include <mysql/mysql.h>
+
+ #ifdef QT_PLUGIN
+ #define Q_EXPORT_SQLDRIVER_MYSQL
diff --git a/source/l/qt5/patches/qt5.private-includes.patch b/source/l/qt5/patches/qt5.private-includes.patch
new file mode 100644
index 00000000..3ef8ebe4
--- /dev/null
+++ b/source/l/qt5/patches/qt5.private-includes.patch
@@ -0,0 +1,53 @@
+# Taken from http://code.qt.io/cgit/qt/qtbase.git/patch/?id=67aa365d
+# ------------------------------------------------------------------
+
+From 67aa365d41ebfe082b4efcfd725e4d5f08be678c Mon Sep 17 00:00:00 2001
+From: Ulf Hermann <ulf.hermann@qt.io>
+Date: Wed, 25 Apr 2018 12:48:21 +0200
+Subject: Do emit CMake declarations for existing private headers
+
+We need to make sure we don't emit CMake declarations for private
+headers if those headers are absent. However, most of the time we have
+private headers and should add them.
+
+Task-number: QTBUG-37417
+Change-Id: I639eb93d008de27928dedac540894af70c1883b9
+Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
+---
+ mkspecs/features/create_cmake.prf | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/mkspecs/features/create_cmake.prf b/mkspecs/features/create_cmake.prf
+index 66acedef55..2ed708e085 100644
+--- a/mkspecs/features/create_cmake.prf
++++ b/mkspecs/features/create_cmake.prf
+@@ -28,9 +28,13 @@ CMAKE_OUT_DIR = $$MODULE_BASE_OUTDIR/lib/cmake
+
+ CMAKE_MODULE_NAME = $$cmakeModuleName($${MODULE})
+
++!generated_privates {
++ isEmpty(SYNCQT.INJECTED_PRIVATE_HEADER_FILES):isEmpty(SYNCQT.PRIVATE_HEADER_FILES): \
++ CMAKE_NO_PRIVATE_INCLUDES = true
++}
++
+ split_incpath {
+ CMAKE_ADD_SOURCE_INCLUDE_DIRS = true
+- CMAKE_NO_PRIVATE_INCLUDES = true # Don't add private includes in the build dir which don't exist
+ CMAKE_SOURCE_INCLUDES = \
+ $$cmakeTargetPaths($$QT_MODULE_INCLUDE_BASE $$QT_MODULE_INCLUDE_BASE/Qt$${CMAKE_MODULE_NAME})
+ CMAKE_SOURCE_PRIVATE_INCLUDES = \
+@@ -53,10 +57,6 @@ contains(CMAKE_INCLUDE_DIR, "^\\.\\./.*") {
+ CMAKE_INCLUDE_DIR_IS_ABSOLUTE = True
+ }
+
+-isEmpty(QT.$${MODULE}_private.includes)| \
+- !exists($$first(QT.$${MODULE}_private.includes)): \
+- CMAKE_NO_PRIVATE_INCLUDES = true
+-
+ CMAKE_LIB_DIR = $$cmakeRelativePath($$[QT_INSTALL_LIBS], $$[QT_INSTALL_PREFIX])
+ contains(CMAKE_LIB_DIR,"^\\.\\./.*") {
+ CMAKE_LIB_DIR = $$[QT_INSTALL_LIBS]/
+--
+cgit v1.1-6-g87c4
+
+
diff --git a/source/l/qt5/patches/qt5.pulseaudio.diff b/source/l/qt5/patches/qt5.pulseaudio.diff
new file mode 100644
index 00000000..8d8f616d
--- /dev/null
+++ b/source/l/qt5/patches/qt5.pulseaudio.diff
@@ -0,0 +1,12 @@
+--- qt-everywhere-opensource-src-5.4.0/qtwebengine/src/3rdparty/chromium/media/media.gyp.orig 2014-12-05 17:26:44.000000000 +0100
++++ qt-everywhere-opensource-src-5.4.0/qtwebengine/src/3rdparty/chromium/media/media.gyp 2014-12-12 10:27:20.393735405 +0100
+@@ -29,7 +29,7 @@
+ ['use_cras==1', {
+ 'use_pulseaudio%': 0,
+ }, {
+- 'use_pulseaudio%': 1,
++ 'use_pulseaudio%': 0,
+ }],
+ ],
+ }, {
+
diff --git a/source/l/qt5/patches/qt5.qlockfile-deadlock.patch b/source/l/qt5/patches/qt5.qlockfile-deadlock.patch
new file mode 100644
index 00000000..e51d5ad0
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qlockfile-deadlock.patch
@@ -0,0 +1,116 @@
+# Taken from:
+# https://projects.archlinux.org/svntogit/packages.git/plain/trunk/qlockfile-deadlock.patch?h=packages/qt5
+# QTBUG-44771
+# ----------------------------------------------------------------------------
+From f58e882b7594c59b6050d3c87562fcf836d10f60 Mon Sep 17 00:00:00 2001
+From: Olivier Goffart <ogoffart@woboq.com>
+Date: Tue, 14 Apr 2015 10:58:26 +0200
+Subject: QLockFile: fix deadlock when the lock file is corrupted
+
+[ChangeLog][QtCore][QLockFile] Fixed a deadlock when the lock file
+is corrupted.
+
+Task-number: QTBUG-44771
+Change-Id: Ic490b09d70ff1cc1733b64949889a73720b2d0f3
+Reviewed-by: David Faure <david.faure@kdab.com>
+---
+ src/corelib/io/qlockfile_unix.cpp | 10 +++++-----
+ src/corelib/io/qlockfile_win.cpp | 22 +++++++++++-----------
+ tests/auto/corelib/io/qlockfile/tst_qlockfile.cpp | 17 +++++++++++++++++
+ 3 files changed, 33 insertions(+), 16 deletions(-)
+
+diff --git a/qtbase/src/corelib/io/qlockfile_unix.cpp b/qtbase/src/corelib/io/qlockfile_unix.cpp
+index bf1015a..dc9f8f7 100644
+--- a/qtbase/src/corelib/io/qlockfile_unix.cpp
++++ b/qtbase/src/corelib/io/qlockfile_unix.cpp
+@@ -181,11 +181,11 @@ bool QLockFilePrivate::isApparentlyStale() const
+ {
+ qint64 pid;
+ QString hostname, appname;
+- if (!getLockInfo(&pid, &hostname, &appname))
+- return false;
+- if (hostname.isEmpty() || hostname == QString::fromLocal8Bit(localHostName())) {
+- if (::kill(pid, 0) == -1 && errno == ESRCH)
+- return true; // PID doesn't exist anymore
++ if (getLockInfo(&pid, &hostname, &appname)) {
++ if (hostname.isEmpty() || hostname == QString::fromLocal8Bit(localHostName())) {
++ if (::kill(pid, 0) == -1 && errno == ESRCH)
++ return true; // PID doesn't exist anymore
++ }
+ }
+ const qint64 age = QFileInfo(fileName).lastModified().msecsTo(QDateTime::currentDateTime());
+ return staleLockTime > 0 && age > staleLockTime;
+diff --git a/qtbase/src/corelib/io/qlockfile_win.cpp b/qtbase/src/corelib/io/qlockfile_win.cpp
+index f9f2909..3587c7b 100644
+--- a/qtbase/src/corelib/io/qlockfile_win.cpp
++++ b/qtbase/src/corelib/io/qlockfile_win.cpp
+@@ -115,21 +115,21 @@ bool QLockFilePrivate::isApparentlyStale() const
+ {
+ qint64 pid;
+ QString hostname, appname;
+- if (!getLockInfo(&pid, &hostname, &appname))
+- return false;
+
+ // On WinRT there seems to be no way of obtaining information about other
+ // processes due to sandboxing
+ #ifndef Q_OS_WINRT
+- if (hostname == QString::fromLocal8Bit(localHostName())) {
+- HANDLE procHandle = ::OpenProcess(PROCESS_QUERY_INFORMATION, FALSE, pid);
+- if (!procHandle)
+- return true;
+- // We got a handle but check if process is still alive
+- DWORD dwR = ::WaitForSingleObject(procHandle, 0);
+- ::CloseHandle(procHandle);
+- if (dwR == WAIT_TIMEOUT)
+- return true;
++ if (getLockInfo(&pid, &hostname, &appname)) {
++ if (hostname == QString::fromLocal8Bit(localHostName())) {
++ HANDLE procHandle = ::OpenProcess(PROCESS_QUERY_INFORMATION, FALSE, pid);
++ if (!procHandle)
++ return true;
++ // We got a handle but check if process is still alive
++ DWORD dwR = ::WaitForSingleObject(procHandle, 0);
++ ::CloseHandle(procHandle);
++ if (dwR == WAIT_TIMEOUT)
++ return true;
++ }
+ }
+ #endif // !Q_OS_WINRT
+ const qint64 age = QFileInfo(fileName).lastModified().msecsTo(QDateTime::currentDateTime());
+diff --git a/qtbase/tests/auto/corelib/io/qlockfile/tst_qlockfile.cpp b/qtbase/tests/auto/corelib/io/qlockfile/tst_qlockfile.cpp
+index 77bef94..12bea67 100644
+--- a/qtbase/tests/auto/corelib/io/qlockfile/tst_qlockfile.cpp
++++ b/qtbase/tests/auto/corelib/io/qlockfile/tst_qlockfile.cpp
+@@ -58,6 +58,7 @@ private slots:
+ void staleLongLockFromBusyProcess();
+ void staleLockRace();
+ void noPermissions();
++ void corruptedLockFile();
+
+ public:
+ QString m_helperApp;
+@@ -415,5 +416,21 @@ void tst_QLockFile::noPermissions()
+ QCOMPARE(int(lockFile.error()), int(QLockFile::PermissionError));
+ }
+
++void tst_QLockFile::corruptedLockFile()
++{
++ const QString fileName = dir.path() + "/corruptedLockFile";
++
++ {
++ // Create a empty file. Typically the result of a computer crash or hard disk full.
++ QFile file(fileName);
++ QVERIFY(file.open(QFile::WriteOnly));
++ }
++
++ QLockFile secondLock(fileName);
++ secondLock.setStaleLockTime(100);
++ QVERIFY(secondLock.tryLock(10000));
++ QCOMPARE(int(secondLock.error()), int(QLockFile::NoError));
++}
++
+ QTEST_MAIN(tst_QLockFile)
+ #include "tst_qlockfile.moc"
+--
+cgit v0.11.0
+
diff --git a/source/l/qt5/patches/qt5.qt5uitoolsconfig.patch b/source/l/qt5/patches/qt5.qt5uitoolsconfig.patch
new file mode 100644
index 00000000..1a0da5b9
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qt5uitoolsconfig.patch
@@ -0,0 +1,17 @@
+The fix for https://bugreports.qt.io/browse/QTBUG-76244 was not complete.
+Further quoting is needed to deal with empty variables.
+-- Eric Hameleers <alien@slackware.com>
+
+--- qt-everywhere-src-5.13.0/qtbase/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in.orig 2019-06-13 06:18:18.000000000 +0200
++++ qt-everywhere-src-5.13.0/qtbase/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in 2019-07-09 19:37:15.253291684 +0200
+@@ -57,8 +57,8 @@
+
+ if(EXISTS \"${prl_file_location}\")
+ file(STRINGS \"${prl_file_location}\" _prl_strings REGEX \"QMAKE_PRL_LIBS[ \\t]*=\")
+- string(REGEX REPLACE \"QMAKE_PRL_LIBS[ \\t]*=[ \\t]*([^\\n]*)\" \"\\\\1\" _static_depends ${_prl_strings})
+- string(REGEX REPLACE \"[ \\t]+\" \";\" _static_depends ${_static_depends})
++ string(REGEX REPLACE \"QMAKE_PRL_LIBS[ \\t]*=[ \\t]*([^\\n]*)\" \"\\\\1\" _static_depends \"${_prl_strings}\")
++ string(REGEX REPLACE \"[ \\t]+\" \";\" _static_depends \"${_static_depends}\")
+ string(REGEX REPLACE \"[ \\t]+\" \";\" _standard_libraries \"${CMAKE_CXX_STANDARD_LIBRARIES}\")
+ set(_search_paths)
+ string(REPLACE \"\\$\\$[QT_INSTALL_LIBS]\" \"${_qt5_install_libs}\" _static_depends \"${_static_depends}\")
diff --git a/source/l/qt5/patches/qt5.qtbase_cmake_isystem_includes.patch b/source/l/qt5/patches/qt5.qtbase_cmake_isystem_includes.patch
new file mode 100644
index 00000000..ff00e63b
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbase_cmake_isystem_includes.patch
@@ -0,0 +1,14 @@
+diff -up qtbase-everywhere-src-5.12.1/src/gui/Qt5GuiConfigExtras.cmake.in.foo qtbase-everywhere-src-5.12.1/src/gui/Qt5GuiConfigExtras.cmake.in
+--- qtbase-everywhere-src-5.12.1/src/gui/Qt5GuiConfigExtras.cmake.in.foo 2019-04-30 15:18:24.886346423 -0500
++++ qtbase-everywhere-src-5.12.1/src/gui/Qt5GuiConfigExtras.cmake.in 2019-04-30 15:19:48.303873296 -0500
+@@ -66,8 +66,10 @@ unset(_GL_INCDIRS)
+ # Don\'t check for existence of the "_qt5gui_OPENGL_INCLUDE_DIR" because it is
+ # optional.
+
++if (NOT ${_qt5gui_OPENGL_INCLUDE_DIR} STREQUAL "/usr/include")
+ list(APPEND Qt5Gui_INCLUDE_DIRS ${_qt5gui_OPENGL_INCLUDE_DIR})
+ set_property(TARGET Qt5::Gui APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${_qt5gui_OPENGL_INCLUDE_DIR})
++endif()
+
+ unset(_qt5gui_OPENGL_INCLUDE_DIR CACHE)
+
diff --git a/source/l/qt5/patches/qt5.qtbug-49061.patch b/source/l/qt5/patches/qt5.qtbug-49061.patch
new file mode 100644
index 00000000..d006edbe
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-49061.patch
@@ -0,0 +1,80 @@
+#
+# https://github.com/qt/qtbase/commit/494376f9.patch
+#
+From 494376f980e96339b6f1eff7c41336ca4d853065 Mon Sep 17 00:00:00 2001
+From: Thiago Macieira <thiago.macieira@intel.com>
+Date: Thu, 12 Nov 2015 10:14:51 -0800
+Subject: [PATCH] Stop unloading plugins in QPluginLoader and QFactoryLoader
+
+QPluginLoader hasn't unloaded in its destructor since Qt 5.0, but we
+missed the equivalent code in QFactoryLoader (which bypasses
+QPluginLoader). Besides, QPluginLoader::unload() was still doing
+unloading, which it won't anymore.
+
+Not unloading plugins is Qt's policy, as decided during the 5.0
+development process and reaffirmed now in 5.6. This is due to static
+data in plugins leaking out and remaining in use past the unloading of
+the plugin, causing crashes.
+
+This does not affect QLibrary and QLibrary::unload(). Those are meant
+for non-Qt loadable modules, so unloading them may be safe.
+
+Task-number: QTBUG-49061
+Discussed-on: http://lists.qt-project.org/pipermail/development/2015-November/023681.html
+Change-Id: I461e9fc7199748faa187ffff1416070f138df8db
+Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
+Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
+---
+ src/corelib/plugin/qfactoryloader.cpp | 6 ++++--
+ src/corelib/plugin/qpluginloader.cpp | 5 +++--
+ 2 files changed, 7 insertions(+), 4 deletions(-)
+
+diff --git a/src/corelib/plugin/qfactoryloader.cpp b/src/corelib/plugin/qfactoryloader.cpp
+index 53b38c3..c820d53 100644
+--- a/src/corelib/plugin/qfactoryloader.cpp
++++ b/src/corelib/plugin/qfactoryloader.cpp
+@@ -203,10 +203,12 @@ void QFactoryLoader::update()
+ ++keyUsageCount;
+ }
+ }
+- if (keyUsageCount || keys.isEmpty())
++ if (keyUsageCount || keys.isEmpty()) {
++ library->setLoadHints(QLibrary::PreventUnloadHint); // once loaded, don't unload
+ d->libraryList += library;
+- else
++ } else {
+ library->release();
++ }
+ }
+ }
+ #else
+diff --git a/src/corelib/plugin/qpluginloader.cpp b/src/corelib/plugin/qpluginloader.cpp
+index 62067c7..4752f69 100644
+--- a/src/corelib/plugin/qpluginloader.cpp
++++ b/src/corelib/plugin/qpluginloader.cpp
+@@ -154,6 +154,7 @@ QPluginLoader::QPluginLoader(const QString &fileName, QObject *parent)
+ : QObject(parent), d(0), did_load(false)
+ {
+ setFileName(fileName);
++ setLoadHints(QLibrary::PreventUnloadHint);
+ }
+
+ /*!
+@@ -348,7 +349,7 @@ static QString locatePlugin(const QString& fileName)
+ void QPluginLoader::setFileName(const QString &fileName)
+ {
+ #if defined(QT_SHARED)
+- QLibrary::LoadHints lh;
++ QLibrary::LoadHints lh = QLibrary::PreventUnloadHint;
+ if (d) {
+ lh = d->loadHints();
+ d->release();
+@@ -394,7 +395,7 @@ QString QPluginLoader::errorString() const
+ \brief Give the load() function some hints on how it should behave.
+
+ You can give hints on how the symbols in the plugin are
+- resolved. By default, none of the hints are set.
++ resolved. By default since Qt 5.7, QLibrary::PreventUnloadHint is set.
+
+ See the documentation of QLibrary::loadHints for a complete
+ description of how this property works.
diff --git a/source/l/qt5/patches/qt5.qtbug-49452.patch b/source/l/qt5/patches/qt5.qtbug-49452.patch
new file mode 100644
index 00000000..4549ff16
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-49452.patch
@@ -0,0 +1,58 @@
+From 6f423555eba55ccdf7287071e10576bc1b687fd2 Mon Sep 17 00:00:00 2001
+From: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
+Date: Mon, 1 Aug 2016 13:39:53 +0200
+Subject: [PATCH] REG: Fix unwanted cache flush in Freetype engine
+
+The Freetype cache was almost completely disabled by
+134c6db8587a8ce156d4fa31ffa62605821851b2 because after that
+change, the lockedAlphaMapForGlyph() function would no longer
+cut off early for empty glyphs like spaces, but rather go
+through all alpha map functions before it realized that there
+was nothing to render. This would in turn invalidate the cache
+for every empty glyph, causing all glyphs to be rerendered for
+every isolated word.
+
+This change adds back a cut off. This is only needed in the
+lockedAlphaMapForGlyph() function, since the superclass implementation
+of the other alpha map functions already contains a cut off for
+width/height == 0.
+
+[ChangeLog][Qt Gui][Text] Fixed a performance regression in Freetype
+engine that was introduced in Qt 5.5.
+
+Change-Id: I381285939909e99cc5fb5f3497fecf9fa871f29a
+Task-number: QTBUG-49452
+Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
+---
+ src/gui/text/qfontengine_ft.cpp | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+diff --git a/src/gui/text/qfontengine_ft.cpp b/src/gui/text/qfontengine_ft.cpp
+index 4de41df..7c878da 100644
+--- a/src/gui/text/qfontengine_ft.cpp
++++ b/src/gui/text/qfontengine_ft.cpp
+@@ -1716,7 +1716,7 @@ glyph_metrics_t QFontEngineFT::alphaMapBoundingBox(glyph_t glyph, QFixed subPixe
+
+ static inline QImage alphaMapFromGlyphData(QFontEngineFT::Glyph *glyph, QFontEngine::GlyphFormat glyphFormat)
+ {
+- if (glyph == Q_NULLPTR)
++ if (glyph == Q_NULLPTR || glyph->height == 0 || glyph->width == 0)
+ return QImage();
+
+ QImage::Format format = QImage::Format_Invalid;
+@@ -1764,11 +1764,15 @@ QImage *QFontEngineFT::lockedAlphaMapForGlyph(glyph_t glyphIndex, QFixed subPixe
+
+ currentlyLockedAlphaMap = alphaMapFromGlyphData(glyph, neededFormat);
+
++ const bool glyphHasGeometry = glyph != Q_NULLPTR && glyph->height != 0 && glyph->width != 0;
+ if (!cacheEnabled && glyph != &emptyGlyph) {
+ currentlyLockedAlphaMap = currentlyLockedAlphaMap.copy();
+ delete glyph;
+ }
+
++ if (!glyphHasGeometry)
++ return Q_NULLPTR;
++
+ if (currentlyLockedAlphaMap.isNull())
+ return QFontEngine::lockedAlphaMapForGlyph(glyphIndex, subPixelPosition, neededFormat, t, offset);
+
diff --git a/source/l/qt5/patches/qt5.qtbug-51621.patch b/source/l/qt5/patches/qt5.qtbug-51621.patch
new file mode 100644
index 00000000..187a3d78
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-51621.patch
@@ -0,0 +1,39 @@
+build with explicitlib after all
+
+unlike speculated in 2fe363514, this is not a workaround at all: it
+causes that libraries' public link interfaces (LIBS) are exported in the
+first place. unlike with staticlib, this does not export LIBS_PRIVATE,
+so it wouldn't even be a particularly effective workaround for rpath
+brokenness anyway.
+
+the problem was pretty well hidden by the qt module system, which at the
+level of libraries is pretty redundant with the .prl file handling,
+which shows just how stupid the whole "design" is.
+
+unlike before, we now enable explicitlib for all libraries, not just qt
+modules - we enable create_prl for all of them as well, after all.
+
+an immediate effect of this change is that it fixes linking on RaspPI:
+the qtcore headers make the user code require linking libatomic, so we
+must add it to our public link interface.
+
+Task-number: QTBUG-51621
+Change-Id: I5742c88694db8e8a9b79d17222dc6df2b38e5ab2
+
+X-Git-Url: https://codereview.qt-project.org/gitweb?p=qt%2Fqtbase.git;a=blobdiff_plain;f=mkspecs%2Ffeatures%2Fqt_build_config.prf;h=b3081b960ec192c3421d7a1c2bd5a628f0ca8455;hp=518fd93f0457c6060721c38ad8b6a0286407e562;hb=268e7ee9778de79d2485bdd028721ec7adbc1324;hpb=495e8c205424253186bef47421de63534d23dd59
+
+diff --git a/mkspecs/features/qt_build_config.prf b/mkspecs/features/qt_build_config.prf
+index 518fd93..b3081b9 100644
+--- a/mkspecs/features/qt_build_config.prf
++++ b/mkspecs/features/qt_build_config.prf
+@@ -72,6 +72,10 @@ CONFIG += \
+ # However, testcases should be still built with exceptions.
+ exceptions_off testcase_exceptions
+
++# Under Windows, this is neither necessary (transitive deps are automatically
++# resolved), nor functional (.res files end up in .prl files and break things).
++unix: CONFIG += explicitlib
++
+
+ defineTest(qtBuildPart) {
+ bp = $$eval($$upper($$section(_QMAKE_CONF_, /, -2, -2))_BUILD_PARTS)
diff --git a/source/l/qt5/patches/qt5.qtbug-51648.patch b/source/l/qt5/patches/qt5.qtbug-51648.patch
new file mode 100644
index 00000000..279839b0
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-51648.patch
@@ -0,0 +1,88 @@
+From b024fbe83863fc57364a52c717d5b43d654bdb5d Mon Sep 17 00:00:00 2001
+From: Weng Xuetian <wengxt@gmail.com>
+Date: Sat, 5 Mar 2016 12:23:21 -0800
+Subject: [PATCH] QtDBus: clean up signal hooks and object tree in
+ closeConnection
+
+If a QObject is added or passed as receiver to QDBusConnection::connect()
+and it is managed by Q_GLOBAL_STATIC or similar mechanism, it is
+possible that when that its destructor is called after the dbus daemon
+thread ends. In that case, QObject::destroyed connected via
+Qt::BlockingQueuedConnection to QDBusConnectionPrivate will cause dead
+lock since the thread is no longer processing events.
+
+Task-number: QTBUG-51648
+Change-Id: I1a1810a6d6d0234af0269d5f3fc1f54101bf1547
+---
+ src/dbus/qdbusconnection_p.h | 1 +
+ src/dbus/qdbusintegrator.cpp | 28 +++++++++++++++++++++++++++-
+ 2 files changed, 28 insertions(+), 1 deletion(-)
+
+diff --git a/src/dbus/qdbusconnection_p.h b/src/dbus/qdbusconnection_p.h
+index c77daf7..565eb83 100644
+--- a/src/dbus/qdbusconnection_p.h
++++ b/src/dbus/qdbusconnection_p.h
+@@ -254,6 +254,7 @@ private:
+ const QVector<int> &metaTypes, int slotIdx);
+
+ SignalHookHash::Iterator removeSignalHookNoLock(SignalHookHash::Iterator it);
++ void disconnectObjectTree(ObjectTreeNode &node);
+
+ bool isServiceRegisteredByThread(const QString &serviceName);
+
+diff --git a/src/dbus/qdbusintegrator.cpp b/src/dbus/qdbusintegrator.cpp
+index cd44861..a3cd47b 100644
+--- a/src/dbus/qdbusintegrator.cpp
++++ b/src/dbus/qdbusintegrator.cpp
+@@ -1030,7 +1030,6 @@ QDBusConnectionPrivate::~QDBusConnectionPrivate()
+ qPrintable(name));
+
+ closeConnection();
+- rootNode.children.clear(); // free resources
+ qDeleteAll(cachedMetaObjects);
+
+ if (mode == ClientMode || mode == PeerMode) {
+@@ -1052,6 +1051,20 @@ QDBusConnectionPrivate::~QDBusConnectionPrivate()
+ }
+ }
+
++void QDBusConnectionPrivate::disconnectObjectTree(QDBusConnectionPrivate::ObjectTreeNode &haystack)
++{
++ QDBusConnectionPrivate::ObjectTreeNode::DataList::Iterator it = haystack.children.begin();
++
++ while (it != haystack.children.end()) {
++ disconnectObjectTree(*it);
++ it++;
++ }
++
++ if (haystack.obj) {
++ haystack.obj->disconnect(this);
++ }
++}
++
+ void QDBusConnectionPrivate::closeConnection()
+ {
+ QDBusWriteLocker locker(CloseConnectionAction, this);
+@@ -1075,6 +1088,19 @@ void QDBusConnectionPrivate::closeConnection()
+ }
+
+ qDeleteAll(pendingCalls);
++
++ // clean up all signal hook and object tree, to avoid QObject::destroyed
++ // being activated to dbus daemon thread which already quits.
++ // dbus connection is already closed, so there is nothing we could do be clean
++ // up everything here.
++ SignalHookHash::iterator sit = signalHooks.begin();
++ while (sit != signalHooks.end()) {
++ sit.value().obj->disconnect(this);
++ sit++;
++ }
++
++ disconnectObjectTree(rootNode);
++ rootNode.children.clear(); // free resources
+ }
+
+ void QDBusConnectionPrivate::checkThread()
+--
+2.7.1
+
diff --git a/source/l/qt5/patches/qt5.qtbug-51649.patch b/source/l/qt5/patches/qt5.qtbug-51649.patch
new file mode 100644
index 00000000..3b7cf9ec
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-51649.patch
@@ -0,0 +1,159 @@
+From acde2e69df5dedc624674107596f276125e22864 Mon Sep 17 00:00:00 2001
+From: Weng Xuetian <wengxt@gmail.com>
+Date: Thu, 3 Mar 2016 21:56:53 -0800
+Subject: [PATCH] QtDBus: finish all pending call with error if disconnected
+
+libdbus will send a local signal if connection gets disconnected. When
+this happens, end all pending calls with QDBusError::Disconnected.
+
+Task-number: QTBUG-51649
+Change-Id: I5c7d2a468bb5da746d0c0e53e458c1e376f186a9
+---
+ src/dbus/dbus_minimal_p.h | 2 ++
+ src/dbus/qdbusintegrator.cpp | 26 +++++++++++++++++-----
+ src/dbus/qdbusutil_p.h | 6 +++++
+ .../dbus/qdbusconnection/tst_qdbusconnection.cpp | 22 ++++++++++++++++++
+ .../dbus/qdbusconnection/tst_qdbusconnection.h | 1 +
+ 5 files changed, 51 insertions(+), 6 deletions(-)
+
+diff --git a/src/dbus/dbus_minimal_p.h b/src/dbus/dbus_minimal_p.h
+index f0a2954..8f25b24 100644
+--- a/src/dbus/dbus_minimal_p.h
++++ b/src/dbus/dbus_minimal_p.h
+@@ -99,9 +99,11 @@ typedef dbus_uint32_t dbus_bool_t;
+ /* dbus-shared.h */
+ #define DBUS_SERVICE_DBUS "org.freedesktop.DBus"
+ #define DBUS_PATH_DBUS "/org/freedesktop/DBus"
++#define DBUS_PATH_LOCAL "/org/freedesktop/DBus/Local"
+ #define DBUS_INTERFACE_DBUS "org.freedesktop.DBus"
+ #define DBUS_INTERFACE_INTROSPECTABLE "org.freedesktop.DBus.Introspectable"
+ #define DBUS_INTERFACE_PROPERTIES "org.freedesktop.DBus.Properties"
++#define DBUS_INTERFACE_LOCAL "org.freedesktop.DBus.Local"
+
+ #define DBUS_NAME_FLAG_ALLOW_REPLACEMENT 0x1 /**< Allow another service to become the primary owner if requested */
+ #define DBUS_NAME_FLAG_REPLACE_EXISTING 0x2 /**< Request to replace the current primary owner */
+diff --git a/src/dbus/qdbusintegrator.cpp b/src/dbus/qdbusintegrator.cpp
+index cd44861..320419f 100644
+--- a/src/dbus/qdbusintegrator.cpp
++++ b/src/dbus/qdbusintegrator.cpp
+@@ -519,6 +519,14 @@ bool QDBusConnectionPrivate::handleMessage(const QDBusMessage &amsg)
+ switch (amsg.type()) {
+ case QDBusMessage::SignalMessage:
+ handleSignal(amsg);
++ // Check local disconnected signal from libdbus
++ if (amsg.interface() == QDBusUtil::dbusInterfaceLocal()
++ && amsg.path() == QDBusUtil::dbusPathLocal()
++ && amsg.member() == QDBusUtil::disconnected()
++ && !QDBusMessagePrivate::isLocal(amsg)) {
++ while (!pendingCalls.isEmpty())
++ processFinishedCall(pendingCalls.first());
++ }
+ // if there are any other filters in this DBusConnection,
+ // let them see the signal too
+ return false;
+@@ -1767,10 +1775,16 @@ void QDBusConnectionPrivate::processFinishedCall(QDBusPendingCallPrivate *call)
+
+ QDBusMessage &msg = call->replyMessage;
+ if (call->pending) {
+- // decode the message
+- DBusMessage *reply = q_dbus_pending_call_steal_reply(call->pending);
+- msg = QDBusMessagePrivate::fromDBusMessage(reply, connection->capabilities);
+- q_dbus_message_unref(reply);
++ // when processFinishedCall is called and pending call is not completed,
++ // it means we received disconnected signal from libdbus
++ if (q_dbus_pending_call_get_completed(call->pending)) {
++ // decode the message
++ DBusMessage *reply = q_dbus_pending_call_steal_reply(call->pending);
++ msg = QDBusMessagePrivate::fromDBusMessage(reply, connection->capabilities);
++ q_dbus_message_unref(reply);
++ } else {
++ msg = QDBusMessage::createError(QDBusError::Disconnected, QDBusUtil::disconnectedErrorMessage());
++ }
+ }
+ qDBusDebug() << connection << "got message reply:" << msg;
+
+@@ -2070,8 +2084,8 @@ void QDBusConnectionPrivate::sendInternal(QDBusPendingCallPrivate *pcall, void *
+ pcall->pending = pending;
+ q_dbus_pending_call_set_notify(pending, qDBusResultReceived, pcall, 0);
+
+- // DBus won't notify us when a peer disconnects so we need to track these ourselves
+- if (mode == QDBusConnectionPrivate::PeerMode)
++ // DBus won't notify us when a peer disconnects or server terminates so we need to track these ourselves
++ if (mode == QDBusConnectionPrivate::PeerMode || mode == QDBusConnectionPrivate::ClientMode)
+ pendingCalls.append(pcall);
+
+ return;
+diff --git a/src/dbus/qdbusutil_p.h b/src/dbus/qdbusutil_p.h
+index 8f5ae92..ca70ff9 100644
+--- a/src/dbus/qdbusutil_p.h
++++ b/src/dbus/qdbusutil_p.h
+@@ -155,6 +155,8 @@ namespace QDBusUtil
+ { return QStringLiteral(DBUS_SERVICE_DBUS); }
+ inline QString dbusPath()
+ { return QStringLiteral(DBUS_PATH_DBUS); }
++ inline QString dbusPathLocal()
++ { return QStringLiteral(DBUS_PATH_LOCAL); }
+ inline QString dbusInterface()
+ {
+ // it's the same string, but just be sure
+@@ -165,8 +167,12 @@ namespace QDBusUtil
+ { return QStringLiteral(DBUS_INTERFACE_PROPERTIES); }
+ inline QString dbusInterfaceIntrospectable()
+ { return QStringLiteral(DBUS_INTERFACE_INTROSPECTABLE); }
++ inline QString dbusInterfaceLocal()
++ { return QStringLiteral(DBUS_INTERFACE_LOCAL); }
+ inline QString nameOwnerChanged()
+ { return QStringLiteral("NameOwnerChanged"); }
++ inline QString disconnected()
++ { return QStringLiteral("Disconnected"); }
+ inline QString disconnectedErrorMessage()
+ { return QStringLiteral("Not connected to D-Bus server"); }
+ }
+diff --git a/tests/auto/dbus/qdbusconnection/tst_qdbusconnection.cpp b/tests/auto/dbus/qdbusconnection/tst_qdbusconnection.cpp
+index e91f87d..6c7e6b1 100644
+--- a/tests/auto/dbus/qdbusconnection/tst_qdbusconnection.cpp
++++ b/tests/auto/dbus/qdbusconnection/tst_qdbusconnection.cpp
+@@ -1218,6 +1218,28 @@ void tst_QDBusConnection::callVirtualObjectLocal()
+ QCOMPARE(obj.replyArguments, subPathReply.arguments());
+ }
+
++void tst_QDBusConnection::pendingCallWhenDisconnected()
++{
++ QDBusServer *server = new QDBusServer;
++ QDBusConnection con = QDBusConnection::connectToPeer(server->address(), "disconnect");
++ QTestEventLoop::instance().enterLoop(2);
++ QVERIFY(!QTestEventLoop::instance().timeout());
++ QVERIFY(con.isConnected());
++
++ delete server;
++
++ // Make sure we call the method before we know it is disconnected.
++ QVERIFY(con.isConnected());
++ QDBusMessage message = QDBusMessage::createMethodCall("", "/", QString(), "method");
++ QDBusPendingCall reply = con.asyncCall(message);
++
++ QTestEventLoop::instance().enterLoop(2);
++ QVERIFY(!con.isConnected());
++ QVERIFY(reply.isFinished());
++ QVERIFY(reply.isError());
++ QVERIFY(reply.error().type() == QDBusError::Disconnected);
++}
++
+ QString MyObject::path;
+ QString MyObjectWithoutInterface::path;
+ QString MyObjectWithoutInterface::interface;
+diff --git a/tests/auto/dbus/qdbusconnection/tst_qdbusconnection.h b/tests/auto/dbus/qdbusconnection/tst_qdbusconnection.h
+index a53ba32..720e484 100644
+--- a/tests/auto/dbus/qdbusconnection/tst_qdbusconnection.h
++++ b/tests/auto/dbus/qdbusconnection/tst_qdbusconnection.h
+@@ -121,6 +121,7 @@ private slots:
+ void registerVirtualObject();
+ void callVirtualObject();
+ void callVirtualObjectLocal();
++ void pendingCallWhenDisconnected();
+
+ public:
+ QString serviceName() const { return "org.qtproject.Qt.Autotests.QDBusConnection"; }
+--
+2.7.1
+
diff --git a/source/l/qt5/patches/qt5.qtbug-51676.patch b/source/l/qt5/patches/qt5.qtbug-51676.patch
new file mode 100644
index 00000000..8672a213
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-51676.patch
@@ -0,0 +1,126 @@
+From 11c5e716b08b6b3c5a7c9fce96b0cde8624ec869 Mon Sep 17 00:00:00 2001
+From: Thiago Macieira <thiago.macieira@intel.com>
+Date: Tue, 15 Mar 2016 11:00:20 -0700
+Subject: [PATCH] Fix QtDBus deadlock inside kded/kiod
+
+Whenever a message spy was installed, we failed to actually process
+looped-back messages by queueing them for processing by the spy. That
+had as a consequence that the caller got an error reply. Worse, since
+the message had been queued, QtDBus would attempt to deliver it later.
+Since that message had isLocal==true, bad things happened inside the
+manager thread.
+
+The correct solution is not to queue the message for the filter. If the
+message is local, then simply deliver directly, as we're still in the
+user's thread. This used to be the behavior in Qt 5.5.
+
+Task-number: QTBUG-51676
+Change-Id: I1dc112894cde7121e8ce302ae51b438ade1ff612
+---
+ src/dbus/qdbusintegrator.cpp | 42 ++++++++++++++++++++++++++++++++----------
+ src/dbus/qdbusintegrator_p.h | 1 +
+ 2 files changed, 33 insertions(+), 10 deletions(-)
+
+diff --git a/src/dbus/qdbusintegrator.cpp b/src/dbus/qdbusintegrator.cpp
+index cd44861..478a2c4 100644
+--- a/src/dbus/qdbusintegrator.cpp
++++ b/src/dbus/qdbusintegrator.cpp
+@@ -481,6 +481,11 @@ QDBusSpyCallEvent::~QDBusSpyCallEvent()
+
+ void QDBusSpyCallEvent::placeMetaCall(QObject *)
+ {
++ invokeSpyHooks(msg, hooks, hookCount);
++}
++
++inline void QDBusSpyCallEvent::invokeSpyHooks(const QDBusMessage &msg, const Hook *hooks, int hookCount)
++{
+ // call the spy hook list
+ for (int i = 0; i < hookCount; ++i)
+ hooks[i](msg);
+@@ -509,7 +514,12 @@ bool QDBusConnectionPrivate::handleMessage(const QDBusMessage &amsg)
+ {
+ if (!ref.load())
+ return false;
+- if (!dispatchEnabled && !QDBusMessagePrivate::isLocal(amsg)) {
++
++ // local message are always delivered, regardless of filtering
++ // or whether the dispatcher is enabled
++ bool isLocal = QDBusMessagePrivate::isLocal(amsg);
++
++ if (!dispatchEnabled && !isLocal) {
+ // queue messages only, we'll handle them later
+ qDBusDebug() << this << "delivery is suspended";
+ pendingMessages << amsg;
+@@ -523,13 +533,23 @@ bool QDBusConnectionPrivate::handleMessage(const QDBusMessage &amsg)
+ // let them see the signal too
+ return false;
+ case QDBusMessage::MethodCallMessage:
+- // run it through the spy filters (if any) before the regular processing
++ // run it through the spy filters (if any) before the regular processing:
++ // a) if it's a local message, we're in the caller's thread, so invoke the filter directly
++ // b) if it's an external message, post to the main thread
+ if (Q_UNLIKELY(qDBusSpyHookList.exists()) && qApp) {
+ const QDBusSpyHookList &list = *qDBusSpyHookList;
+- qDBusDebug() << this << "invoking message spies";
+- QCoreApplication::postEvent(qApp, new QDBusSpyCallEvent(this, QDBusConnection(this),
+- amsg, list.constData(), list.size()));
+- return true;
++ if (isLocal) {
++ Q_ASSERT(QThread::currentThread() != thread());
++ qDBusDebug() << this << "invoking message spies directly";
++ QDBusSpyCallEvent::invokeSpyHooks(amsg, list.constData(), list.size());
++ } else {
++ qDBusDebug() << this << "invoking message spies via event";
++ QCoreApplication::postEvent(qApp, new QDBusSpyCallEvent(this, QDBusConnection(this),
++ amsg, list.constData(), list.size()));
++
++ // we'll be called back, so return
++ return true;
++ }
+ }
+
+ handleObjectCall(amsg);
+@@ -1451,9 +1471,9 @@ void QDBusConnectionPrivate::handleObjectCall(const QDBusMessage &msg)
+ // that means the dispatchLock mutex is locked
+ // must not call out to user code in that case
+ //
+- // however, if the message is internal, handleMessage was called
+- // directly and no lock is in place. We can therefore call out to
+- // user code, if necessary
++ // however, if the message is internal, handleMessage was called directly
++ // (user's thread) and no lock is in place. We can therefore call out to
++ // user code, if necessary.
+ ObjectTreeNode result;
+ int usedLength;
+ QThread *objThread = 0;
+@@ -1492,12 +1512,14 @@ void QDBusConnectionPrivate::handleObjectCall(const QDBusMessage &msg)
+ usedLength, msg));
+ return;
+ } else if (objThread != QThread::currentThread()) {
+- // synchronize with other thread
++ // looped-back message, targeting another thread:
++ // synchronize with it
+ postEventToThread(HandleObjectCallPostEventAction, result.obj,
+ new QDBusActivateObjectEvent(QDBusConnection(this), this, result,
+ usedLength, msg, &sem));
+ semWait = true;
+ } else {
++ // looped-back message, targeting current thread
+ semWait = false;
+ }
+ } // release the lock
+diff --git a/src/dbus/qdbusintegrator_p.h b/src/dbus/qdbusintegrator_p.h
+index 2bbebdf..c0d9c22 100644
+--- a/src/dbus/qdbusintegrator_p.h
++++ b/src/dbus/qdbusintegrator_p.h
+@@ -145,6 +145,7 @@ public:
+ {}
+ ~QDBusSpyCallEvent();
+ void placeMetaCall(QObject *) Q_DECL_OVERRIDE;
++ static inline void invokeSpyHooks(const QDBusMessage &msg, const Hook *hooks, int hookCount);
+
+ QDBusConnection conn; // keeps the refcount in QDBusConnectionPrivate up
+ QDBusMessage msg;
+--
+2.7.1
+
diff --git a/source/l/qt5/patches/qt5.qtbug-51890.patch b/source/l/qt5/patches/qt5.qtbug-51890.patch
new file mode 100644
index 00000000..51168b90
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-51890.patch
@@ -0,0 +1,82 @@
+QTBUG-51890: qtwebengine fails to build with system nss 3.23
+Patch obtained from:
+https://github.com/qtproject/qtwebengine/commit/82900c7b96b2a6fb42fe3841df7685b820edd588.patch
+
+And modified to exclude the "Subproject commit" lines.
+
+# ----------------------------------------------------------------------------
+
+From 82900c7b96b2a6fb42fe3841df7685b820edd588 Mon Sep 17 00:00:00 2001
+From: Kai Koehne <kai.koehne@theqtcompany.com>
+Date: Thu, 24 Mar 2016 13:55:28 +0100
+Subject: [PATCH] Use system NSS only for certificate handling
+
+Compiling against NSS 3.23 fails with current Chromium. Also, with NSS
+3.21 there are failures connecting to e.g. google.com.
+
+Fix this by adapting the setup endorsed by upstream Chromium: BoringSSL
+is always used for cryptography, and NSS only for certificate handlng.
+
+Patches included in 3rdparty update:
+
+0a385bb [backport] Call EnsureNSSHttpIOInit in the chimera build.
+0472123 Fix build against newer NSS
+90c62c4 <third_party/libpng> [Backport] update to libpng 1.2.56
+34857b8 <third_party/libpng> [Backport] Stop large iCCP chunks causing delays and "Aw Snap!"
+
+Task-number: QTBUG-52193
+Task-number: QTBUG-51890
+Task-number: QTBUG-52068
+Change-Id: If8aaed9b9a09475c5ed0dfec64d31f45ce9670f5
+Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
+---
+ src/3rdparty | 2 +-
+ src/core/config/linux.pri | 9 ++++++---
+ tools/qmake/mkspecs/features/configure.prf | 4 ++--
+ 3 files changed, 9 insertions(+), 6 deletions(-)
+
+#diff --git a/src/3rdparty b/src/3rdparty
+#index 3b2b78c..0a385bb 160000
+#--- a/src/3rdparty
+#+++ b/src/3rdparty
+#@@ -1 +1 @@
+#-Subproject commit 3b2b78caa761db2b7b25dc51c3dae8316f595db1
+#+Subproject commit 0a385bb01d9cf060fae4c9d350ee98561654df96
+diff --git a/src/core/config/linux.pri b/src/core/config/linux.pri
+index 88c1a41..39eeb2a 100644
+--- a/src/core/config/linux.pri
++++ b/src/core/config/linux.pri
+@@ -18,11 +18,14 @@ GYP_CONFIG += \
+ use_gio=0 \
+ use_gnome_keyring=0 \
+ use_kerberos=0 \
+- use_pango=0
++ use_pango=0 \
++ use_openssl=1
+
+-!use?(nss) {
++use?(nss) {
++ GYP_CONFIG += use_nss_certs=1 \
++ use_openssl_certs=0
++} else {
+ GYP_CONFIG += use_nss_certs=0 \
+- use_openssl=1 \
+ use_openssl_certs=1
+ }
+
+diff --git a/tools/qmake/mkspecs/features/configure.prf b/tools/qmake/mkspecs/features/configure.prf
+index 4cb4600..953572d 100644
+--- a/tools/qmake/mkspecs/features/configure.prf
++++ b/tools/qmake/mkspecs/features/configure.prf
+@@ -72,9 +72,9 @@ defineTest(runConfigure) {
+ defineTest(finalizeConfigure) {
+ linux {
+ use?(nss) {
+- log("SSL............................... Using system NSS$${EOL}")
++ log("Certificate handling.............. Using system NSS$${EOL}")
+ } else {
+- log("SSL............................... Using bundled BoringSSL$${EOL}")
++ log("Certificate handling.............. Using bundled BoringSSL$${EOL}")
+ }
+ use?(system_icu) {
+ packagesExist("icu-uc icu-i18n") {
diff --git a/source/l/qt5/patches/qt5.qtbug-51927.patch b/source/l/qt5/patches/qt5.qtbug-51927.patch
new file mode 100644
index 00000000..d253dc15
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-51927.patch
@@ -0,0 +1,185 @@
+From 5149aa68eca6ede8836ec4f07a14d22d9da9b161 Mon Sep 17 00:00:00 2001
+From: Mitch Curtis <mitch.curtis@qt.io>
+Date: Tue, 13 Sep 2016 12:42:12 +0200
+Subject: Fix crash on exit when using default property aliases with layouts
+
+The layout was being destroyed before the text, which meant that the
+removeItemChangeListener() call never got hit. To ensure that the
+listener is always removed, loop through each child in QQuickLayout's
+destructor.
+
+This is a manual cherry-pick of
+59c6c0e0b1b5b46747595a58e11311b7393d7e70.
+
+Task-number: QTBUG-51927
+Change-Id: I669f42beb8c3dd6b4b741cae0b16e017bb3409df
+Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
+---
+ src/imports/layouts/qquicklayout.cpp | 4 ++
+ .../qquicklayouts/data/rowlayout/Container.qml | 55 ++++++++++++++++++++++
+ .../qquicklayouts/data/rowlayout/ContainerUser.qml | 53 +++++++++++++++++++++
+ .../quick/qquicklayouts/data/tst_rowlayout.qml | 12 +++++
+ 4 files changed, 124 insertions(+)
+ create mode 100644 tests/auto/quick/qquicklayouts/data/rowlayout/Container.qml
+ create mode 100644 tests/auto/quick/qquicklayouts/data/rowlayout/ContainerUser.qml
+
+diff --git a/src/imports/layouts/qquicklayout.cpp b/src/imports/layouts/qquicklayout.cpp
+index abc8f97..9914826 100644
+--- a/src/imports/layouts/qquicklayout.cpp
++++ b/src/imports/layouts/qquicklayout.cpp
+@@ -698,6 +698,10 @@ QQuickLayout::QQuickLayout(QQuickLayoutPrivate &dd, QQuickItem *parent)
+ QQuickLayout::~QQuickLayout()
+ {
+ d_func()->m_isReady = false;
++
++ const auto childItems = d_func()->childItems;
++ for (QQuickItem *child : childItems)
++ QQuickItemPrivate::get(child)->removeItemChangeListener(this, QQuickItemPrivate::SiblingOrder);
+ }
+
+ QQuickLayoutAttached *QQuickLayout::qmlAttachedProperties(QObject *object)
+diff --git a/tests/auto/quick/qquicklayouts/data/rowlayout/Container.qml b/tests/auto/quick/qquicklayouts/data/rowlayout/Container.qml
+new file mode 100644
+index 0000000..22205c1
+--- /dev/null
++++ b/tests/auto/quick/qquicklayouts/data/rowlayout/Container.qml
+@@ -0,0 +1,55 @@
++/****************************************************************************
++**
++** Copyright (C) 2016 The Qt Company Ltd.
++** Contact: http://www.qt.io/licensing/
++**
++** This file is part of the test suite of the Qt Toolkit.
++**
++** $QT_BEGIN_LICENSE:BSD$
++** You may use this file under the terms of the BSD license as follows:
++**
++** "Redistribution and use in source and binary forms, with or without
++** modification, are permitted provided that the following conditions are
++** met:
++** * Redistributions of source code must retain the above copyright
++** notice, this list of conditions and the following disclaimer.
++** * Redistributions in binary form must reproduce the above copyright
++** notice, this list of conditions and the following disclaimer in
++** the documentation and/or other materials provided with the
++** distribution.
++** * Neither the name of The Qt Company Ltd nor the names of its
++** contributors may be used to endorse or promote products derived
++** from this software without specific prior written permission.
++**
++**
++** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
++** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
++** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
++** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
++** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
++** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
++** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
++** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
++** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
++** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
++** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
++**
++** $QT_END_LICENSE$
++**
++****************************************************************************/
++
++import QtQuick 2.7
++import QtQuick.Layouts 1.3
++
++Item {
++ objectName: "qtbug51927-window"
++ visible: true
++
++ default property alias _contents: customContent.data
++
++ RowLayout {
++ id: customContent
++ objectName: "qtbug51927-columnLayout"
++ anchors.fill: parent
++ }
++}
+diff --git a/tests/auto/quick/qquicklayouts/data/rowlayout/ContainerUser.qml b/tests/auto/quick/qquicklayouts/data/rowlayout/ContainerUser.qml
+new file mode 100644
+index 0000000..ff7ce62
+--- /dev/null
++++ b/tests/auto/quick/qquicklayouts/data/rowlayout/ContainerUser.qml
+@@ -0,0 +1,53 @@
++/****************************************************************************
++**
++** Copyright (C) 2016 The Qt Company Ltd.
++** Contact: http://www.qt.io/licensing/
++**
++** This file is part of the test suite of the Qt Toolkit.
++**
++** $QT_BEGIN_LICENSE:BSD$
++** You may use this file under the terms of the BSD license as follows:
++**
++** "Redistribution and use in source and binary forms, with or without
++** modification, are permitted provided that the following conditions are
++** met:
++** * Redistributions of source code must retain the above copyright
++** notice, this list of conditions and the following disclaimer.
++** * Redistributions in binary form must reproduce the above copyright
++** notice, this list of conditions and the following disclaimer in
++** the documentation and/or other materials provided with the
++** distribution.
++** * Neither the name of The Qt Company Ltd nor the names of its
++** contributors may be used to endorse or promote products derived
++** from this software without specific prior written permission.
++**
++**
++** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
++** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
++** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
++** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
++** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
++** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
++** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
++** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
++** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
++** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
++** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
++**
++** $QT_END_LICENSE$
++**
++****************************************************************************/
++
++import QtQuick 2.6
++import QtQuick.Window 2.2
++
++Container {
++ visible: true
++
++ Text {
++ objectName: "qtbug51927-text"
++ text: qsTr("Hello World")
++ anchors.centerIn: parent
++ renderType: Text.QtRendering
++ }
++}
+diff --git a/tests/auto/quick/qquicklayouts/data/tst_rowlayout.qml b/tests/auto/quick/qquicklayouts/data/tst_rowlayout.qml
+index 33b8fd0..2d4e227 100644
+--- a/tests/auto/quick/qquicklayouts/data/tst_rowlayout.qml
++++ b/tests/auto/quick/qquicklayouts/data/tst_rowlayout.qml
+@@ -926,5 +926,17 @@ Item {
+ waitForRendering(layout)
+ layout.destroy()
+ }
++
++
++ function test_defaultPropertyAliasCrash() {
++ var containerUserComponent = Qt.createComponent("rowlayout/ContainerUser.qml");
++ compare(containerUserComponent.status, Component.Ready);
++
++ var containerUser = containerUserComponent.createObject(testCase);
++ verify(containerUser);
++
++ // Shouldn't crash.
++ containerUser.destroy();
++ }
+ }
+ }
+--
+cgit v1.0-4-g1e03
+
diff --git a/source/l/qt5/patches/qt5.qtbug-53237.patch b/source/l/qt5/patches/qt5.qtbug-53237.patch
new file mode 100644
index 00000000..c6d5739d
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-53237.patch
@@ -0,0 +1,90 @@
+From 8e889378115c69508b050a511621ac8e30ec4158 Mon Sep 17 00:00:00 2001
+From: Jesus Fernandez <jesus.fernandez@theqtcompany.com>
+Date: Mon, 13 Jun 2016 19:09:15 +0200
+Subject: [PATCH] Fix UNSIGNED values in QMYSQL
+
+The unsigned flag in columns was ignored when creating the list of
+bound values in a mysql table. So the result iteration with
+QSqlQuery::next stops after the first wrong truncated value.
+
+[ChangeLog][QtSql] Fixed QSqlQuery::prepare value truncation error when
+using UNSIGNED values in a MySQL database.
+
+Task-number: QTBUG-53969
+Task-number: QTBUG-53237
+Change-Id: I10d977993445f2794f1dd8c88b2e83517ef524f3
+Reviewed-by: Milian Wolff <milian.wolff@kdab.com>
+---
+ src/sql/drivers/mysql/qsql_mysql.cpp | 1 +
+ tests/auto/sql/kernel/qsqlquery/tst_qsqlquery.cpp | 39 +++++++++++++++++++++++
+ 2 files changed, 40 insertions(+)
+
+diff --git a/src/sql/drivers/mysql/qsql_mysql.cpp b/src/sql/drivers/mysql/qsql_mysql.cpp
+index 96bdcc4..55bf499 100644
+--- a/src/sql/drivers/mysql/qsql_mysql.cpp
++++ b/src/sql/drivers/mysql/qsql_mysql.cpp
+@@ -387,6 +387,7 @@ bool QMYSQLResultPrivate::bindInValues()
+ bind->buffer_length = f.bufLength = fieldInfo->length + 1;
+ bind->is_null = &f.nullIndicator;
+ bind->length = &f.bufLength;
++ bind->is_unsigned = fieldInfo->flags & UNSIGNED_FLAG ? 1 : 0;
+ f.outField=field;
+
+ ++i;
+diff --git a/tests/auto/sql/kernel/qsqlquery/tst_qsqlquery.cpp b/tests/auto/sql/kernel/qsqlquery/tst_qsqlquery.cpp
+index bd553d5..f1c4333 100644
+--- a/tests/auto/sql/kernel/qsqlquery/tst_qsqlquery.cpp
++++ b/tests/auto/sql/kernel/qsqlquery/tst_qsqlquery.cpp
+@@ -233,6 +233,9 @@ private slots:
+ void QTBUG_36211_data() { generic_data("QPSQL"); }
+ void QTBUG_36211();
+
++ void QTBUG_53969_data() { generic_data("QMYSQL"); }
++ void QTBUG_53969();
++
+ void sqlite_constraint_data() { generic_data("QSQLITE"); }
+ void sqlite_constraint();
+
+@@ -3652,6 +3655,42 @@ void tst_QSqlQuery::QTBUG_36211()
+ }
+ }
+
++void tst_QSqlQuery::QTBUG_53969()
++{
++ QFETCH( QString, dbName );
++ QVector<int> values = QVector<int>() << 10 << 20 << 127 << 128 << 1, tableValues;
++ QSqlDatabase db = QSqlDatabase::database( dbName );
++ CHECK_DATABASE( db );
++ tableValues.reserve(values.size());
++ if (tst_Databases::getDatabaseType(db) == QSqlDriver::MySqlServer) {
++ const QString tableName(qTableName("bug53969", __FILE__, db));
++ tst_Databases::safeDropTable( db, tableName );
++
++ QSqlQuery q(db);
++ QVERIFY_SQL(q, exec(QString("CREATE TABLE %1 (id INT AUTO_INCREMENT PRIMARY KEY, "
++ "test_number TINYINT(3) UNSIGNED)")
++ .arg(tableName)));
++
++ QVERIFY_SQL(q, prepare("INSERT INTO " + tableName + " (test_number) VALUES (:value)"));
++
++ QVector<int>::iterator begin = values.begin(), end = values.end(), it;
++ for (it = begin; it != end; ++it) {
++ q.bindValue(":value", *it);
++ QVERIFY_SQL(q, exec());
++ }
++
++ QVERIFY_SQL(q, prepare("SELECT test_number FROM " + tableName));
++ QVERIFY_SQL(q, exec());
++
++ while (q.next()) {
++ bool ok;
++ tableValues.push_back(q.value(0).toUInt(&ok));
++ QVERIFY(ok);
++ }
++ QCOMPARE(values, tableValues);
++ }
++}
++
+ void tst_QSqlQuery::oraOCINumber()
+ {
+ QFETCH( QString, dbName );
diff --git a/source/l/qt5/patches/qt5.qtbug-55583.patch b/source/l/qt5/patches/qt5.qtbug-55583.patch
new file mode 100644
index 00000000..804f5383
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-55583.patch
@@ -0,0 +1,41 @@
+#
+# https://github.com/qt/qtbase/commit/84ea00d4.patch
+#
+From 84ea00d47049d882f2fabf1446ec6c6eb5fe3038 Mon Sep 17 00:00:00 2001
+From: J-P Nurmi <jpnurmi@qt.io>
+Date: Tue, 6 Dec 2016 16:30:31 +0100
+Subject: [PATCH] QGtk3Dialog: don't crash on Wayland
+
+Check if it's an X11 window before calling XSetTransientForHint().
+No transient parent will be set for GTK+ dialogs on Wayland. That
+has to be implemented separately.
+
+Task-number: QTBUG-55583
+Change-Id: Iabc2a72681c8157bb2f2fe500892853aa397106b
+Reviewed-by: Dmitry Shachnev <mitya57@gmail.com>
+Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
+---
+ src/plugins/platformthemes/gtk3/qgtk3dialoghelpers.cpp | 10 ++++++----
+ 1 file changed, 6 insertions(+), 4 deletions(-)
+
+diff --git a/src/plugins/platformthemes/gtk3/qgtk3dialoghelpers.cpp b/src/plugins/platformthemes/gtk3/qgtk3dialoghelpers.cpp
+index ba5089a..699b058 100644
+--- a/src/plugins/platformthemes/gtk3/qgtk3dialoghelpers.cpp
++++ b/src/plugins/platformthemes/gtk3/qgtk3dialoghelpers.cpp
+@@ -135,10 +135,12 @@ bool QGtk3Dialog::show(Qt::WindowFlags flags, Qt::WindowModality modality, QWind
+
+ GdkWindow *gdkWindow = gtk_widget_get_window(gtkWidget);
+ if (parent) {
+- GdkDisplay *gdkDisplay = gdk_window_get_display(gdkWindow);
+- XSetTransientForHint(gdk_x11_display_get_xdisplay(gdkDisplay),
+- gdk_x11_window_get_xid(gdkWindow),
+- parent->winId());
++ if (GDK_IS_X11_WINDOW(gdkWindow)) {
++ GdkDisplay *gdkDisplay = gdk_window_get_display(gdkWindow);
++ XSetTransientForHint(gdk_x11_display_get_xdisplay(gdkDisplay),
++ gdk_x11_window_get_xid(gdkWindow),
++ parent->winId());
++ }
+ }
+
+ if (modality != Qt::NonModal) {
diff --git a/source/l/qt5/patches/qt5.qtbug-60558.patch b/source/l/qt5/patches/qt5.qtbug-60558.patch
new file mode 100644
index 00000000..2d039203
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-60558.patch
@@ -0,0 +1,32 @@
+https://github.com/qt/qtbase/commit/f45c6c18.patch
+
+From f45c6c180463ccb6620e1d273a264f14a1204a93 Mon Sep 17 00:00:00 2001
+From: Thiago Macieira <thiago.macieira@intel.com>
+Date: Wed, 3 May 2017 14:08:50 -0700
+Subject: [PATCH] QInternal::unregisterCallback: don't crash on unregistering
+ during exit
+
+Task-number: QTBUG-60558
+Change-Id: Ica9894dc9b5e48278fd4fffd14bb34c6d98d2555
+Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
+---
+ src/corelib/global/qglobal.cpp | 6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/src/corelib/global/qglobal.cpp b/src/corelib/global/qglobal.cpp
+index c37503f3db..22fc20d47e 100644
+--- a/src/corelib/global/qglobal.cpp
++++ b/src/corelib/global/qglobal.cpp
+@@ -3988,8 +3988,10 @@ bool QInternal::registerCallback(Callback cb, qInternalCallback callback)
+ bool QInternal::unregisterCallback(Callback cb, qInternalCallback callback)
+ {
+ if (cb >= 0 && cb < QInternal::LastCallback) {
+- QInternal_CallBackTable *cbt = global_callback_table();
+- return (bool) cbt->callbacks[cb].removeAll(callback);
++ if (global_callback_table.exists()) {
++ QInternal_CallBackTable *cbt = global_callback_table();
++ return (bool) cbt->callbacks[cb].removeAll(callback);
++ }
+ }
+ return false;
+ }
diff --git a/source/l/qt5/patches/qt5.qtbug-61140.patch b/source/l/qt5/patches/qt5.qtbug-61140.patch
new file mode 100644
index 00000000..17468a95
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-61140.patch
@@ -0,0 +1,101 @@
+https://github.com/qt/qtbase/commit/744fd39e.patch
+
+From 744fd39e66b0b44e65a2505d674fa1cda8b205a4 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Tor=20Arne=20Vestb=C3=B8?= <tor.arne.vestbo@qt.io>
+Date: Fri, 2 Jun 2017 11:09:55 +0200
+Subject: [PATCH] xcb: Don't destroy foreign windows
+
+We can't rely on virtual dispatch in the destructor.
+
+Task-number: QTBUG-61140
+Change-Id: Ib1026caf126095778c24254775cb5a0bfecf3a38
+Reviewed-by: Fabian Vogt
+Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
+---
+ src/plugins/platforms/xcb/qxcbintegration.cpp | 18 +-----------------
+ src/plugins/platforms/xcb/qxcbwindow.cpp | 16 ++++++++++------
+ src/plugins/platforms/xcb/qxcbwindow.h | 12 ++++++++++++
+ 3 files changed, 23 insertions(+), 23 deletions(-)
+
+diff --git a/src/plugins/platforms/xcb/qxcbintegration.cpp b/src/plugins/platforms/xcb/qxcbintegration.cpp
+index b414bee204..8e3ee20329 100644
+--- a/src/plugins/platforms/xcb/qxcbintegration.cpp
++++ b/src/plugins/platforms/xcb/qxcbintegration.cpp
+@@ -214,25 +214,9 @@ QPlatformWindow *QXcbIntegration::createPlatformWindow(QWindow *window) const
+ return xcbWindow;
+ }
+
+-class QXcbForeignWindow : public QXcbWindow
+-{
+-public:
+- QXcbForeignWindow(QWindow *window, WId nativeHandle)
+- : QXcbWindow(window) { m_window = nativeHandle; }
+- ~QXcbForeignWindow() {}
+- bool isForeignWindow() const override { return true; }
+-
+-protected:
+- // No-ops
+- void create() override {}
+- void destroy() override {}
+-};
+-
+ QPlatformWindow *QXcbIntegration::createForeignWindow(QWindow *window, WId nativeHandle) const
+ {
+- QXcbWindow *xcbWindow = new QXcbForeignWindow(window, nativeHandle);
+- xcbWindow->create();
+- return xcbWindow;
++ return new QXcbForeignWindow(window, nativeHandle);
+ }
+
+ #ifndef QT_NO_OPENGL
+diff --git a/src/plugins/platforms/xcb/qxcbwindow.cpp b/src/plugins/platforms/xcb/qxcbwindow.cpp
+index 289d0720e7..d6c69d52ef 100644
+--- a/src/plugins/platforms/xcb/qxcbwindow.cpp
++++ b/src/plugins/platforms/xcb/qxcbwindow.cpp
+@@ -597,13 +597,17 @@ QXcbWindow::~QXcbWindow()
+ }
+
+ destroy();
++}
+
+- if (isForeignWindow()) {
+- if (connection()->mouseGrabber() == this)
+- connection()->setMouseGrabber(Q_NULLPTR);
+- if (connection()->mousePressWindow() == this)
+- connection()->setMousePressWindow(Q_NULLPTR);
+- }
++QXcbForeignWindow::~QXcbForeignWindow()
++{
++ // Clear window so that destroy() does not affect it
++ m_window = 0;
++
++ if (connection()->mouseGrabber() == this)
++ connection()->setMouseGrabber(nullptr);
++ if (connection()->mousePressWindow() == this)
++ connection()->setMousePressWindow(nullptr);
+ }
+
+ void QXcbWindow::destroy()
+diff --git a/src/plugins/platforms/xcb/qxcbwindow.h b/src/plugins/platforms/xcb/qxcbwindow.h
+index 56628094ee..f38343b6c2 100644
+--- a/src/plugins/platforms/xcb/qxcbwindow.h
++++ b/src/plugins/platforms/xcb/qxcbwindow.h
+@@ -278,6 +278,18 @@ public Q_SLOTS:
+ xcb_cursor_t m_currentBitmapCursor = XCB_CURSOR_NONE;
+ };
+
++class QXcbForeignWindow : public QXcbWindow
++{
++public:
++ QXcbForeignWindow(QWindow *window, WId nativeHandle)
++ : QXcbWindow(window) { m_window = nativeHandle; }
++ ~QXcbForeignWindow();
++ bool isForeignWindow() const override { return true; }
++
++protected:
++ void create() override {} // No-op
++};
++
+ QT_END_NAMESPACE
+
+ Q_DECLARE_METATYPE(QXcbWindow*)
diff --git a/source/l/qt5/patches/qt5.qtbug-66103.patch b/source/l/qt5/patches/qt5.qtbug-66103.patch
new file mode 100644
index 00000000..62d1b301
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-66103.patch
@@ -0,0 +1,172 @@
+https://code.qt.io/cgit/qt/qtbase.git/patch/?id=4a7771f206d4b29be549d3827c36a46679d90de6
+
+From 4a7771f206d4b29be549d3827c36a46679d90de6 Mon Sep 17 00:00:00 2001
+From: Eike Hein <hein@kde.org>
+Date: Sun, 7 Jan 2018 13:02:01 +0900
+Subject: QSimpleDrag: Fix mouse release coords for delayed event transmission
+
+On platforms such as XCB, the drag cursor pixmap is shown via a window
+(a QShapedPixmapWindow) under the cursor.
+
+The mouse button release event at the end of the drag is received in
+this QXcbWindow, but intercepted by an event filter that QSimpleDrag
+installs on the QApplication. It then resends it unmodified(!) after
+the drag has ended and the drag pixmap window destroyed, causing it to
+be delivered to the new top-level window.
+
+The local coordinates in the unmodified QMouseEvent are local to the
+drag pixmap window and don't match the window it is delayed-transmitted
+to.
+
+This ends up having fatal, user-visible effects particularly in Qt
+Quick: QQuickWindow synthesizes a hover event once per frame using
+the last received mouse coordinates, here: the release posted by
+QSimpleDrag. This is done to update the hover event state for items
+under the cursor when the mouse hasn't moved (e.g. QQuickMouseArea::
+containsMouse). The bogus event coordinates in the release event then
+usually end up causing an item near the top-left of the QQuickWindow
+to assume it is hovered (because drag pixmap windows tend to be small),
+even when the mouse cursor is actually far away from it at the end of
+the drag.
+
+This shows up e.g. in the Plasma 5 desktop, where dragging an icon
+on the desktop will cause the icon at the top-left of the screen (if
+any) to switch to hovered state, as the release coordinates on the
+drag pixmap window (showing a dragged icon) fall into the geometry
+of the top-left icon.
+
+QSimpleDrag contains a topLevelAt() function to find the top-level
+window under the global cursor coordinates that is not the drag
+pixmap window. This is used by the drop event delivery code.
+
+This patch uses this function to find the relevant top-level window,
+then asks it to map the global cusor coordinates to its local
+coordinate system, then synthesizes a new QMouseEvent with local
+coordinates computed in this fashion. As a result the window now
+gets a release event with coordinates that make sense and are
+correct.
+
+Task-number: QTBUG-66103
+Change-Id: I04ebe6ccd4a991fdd4b540ff0227973ea8896a9d
+Reviewed-by: Eike Hein <hein@kde.org>
+Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
+---
+ src/gui/kernel/qsimpledrag.cpp | 32 +++++++++++++++++++++++++++-----
+ src/gui/kernel/qsimpledrag_p.h | 6 +++---
+ 2 files changed, 30 insertions(+), 8 deletions(-)
+
+diff --git a/src/gui/kernel/qsimpledrag.cpp b/src/gui/kernel/qsimpledrag.cpp
+index a1e25dc53c..87d3ba5915 100644
+--- a/src/gui/kernel/qsimpledrag.cpp
++++ b/src/gui/kernel/qsimpledrag.cpp
+@@ -58,6 +58,7 @@
+
+ #include <QtCore/QEventLoop>
+ #include <QtCore/QDebug>
++#include <QtCore/QLoggingCategory>
+
+ #include <private/qguiapplication_p.h>
+ #include <private/qdnd_p.h>
+@@ -69,6 +70,8 @@ QT_BEGIN_NAMESPACE
+
+ #ifndef QT_NO_DRAGANDDROP
+
++Q_LOGGING_CATEGORY(lcDnd, "qt.gui.dnd")
++
+ static QWindow* topLevelAt(const QPoint &pos)
+ {
+ QWindowList list = QGuiApplication::topLevelWindows();
+@@ -94,10 +97,10 @@ static QWindow* topLevelAt(const QPoint &pos)
+ */
+
+ QBasicDrag::QBasicDrag() :
+- m_restoreCursor(false), m_eventLoop(0),
++ m_current_window(nullptr), m_restoreCursor(false), m_eventLoop(nullptr),
+ m_executed_drop_action(Qt::IgnoreAction), m_can_drop(false),
+- m_drag(0), m_drag_icon_window(0), m_useCompositing(true),
+- m_screen(Q_NULLPTR)
++ m_drag(nullptr), m_drag_icon_window(nullptr), m_useCompositing(true),
++ m_screen(nullptr)
+ {
+ }
+
+@@ -161,6 +164,7 @@ bool QBasicDrag::eventFilter(QObject *o, QEvent *e)
+ return true; // Eat all mouse move events
+ }
+ case QEvent::MouseButtonRelease:
++ {
+ disableEventFilter();
+ if (canDrop()) {
+ QPoint nativePosition = getNativeMousePos(e, m_drag_icon_window);
+@@ -169,8 +173,25 @@ bool QBasicDrag::eventFilter(QObject *o, QEvent *e)
+ cancel();
+ }
+ exitDndEventLoop();
+- QCoreApplication::postEvent(o, new QMouseEvent(*static_cast<QMouseEvent *>(e)));
++
++ // If a QShapedPixmapWindow (drag feedback) is being dragged along, the
++ // mouse event's localPos() will be relative to that, which is useless.
++ // We want a position relative to the window where the drag ends, if possible (?).
++ // If there is no such window (belonging to this Qt application),
++ // make the event relative to the window where the drag started. (QTBUG-66103)
++ const QMouseEvent *release = static_cast<QMouseEvent *>(e);
++ const QWindow *releaseWindow = topLevelAt(release->globalPos());
++ qCDebug(lcDnd) << "mouse released over" << releaseWindow << "after drag from" << m_current_window << "globalPos" << release->globalPos();
++ if (!releaseWindow)
++ releaseWindow = m_current_window;
++ QPoint releaseWindowPos = (releaseWindow ? releaseWindow->mapFromGlobal(release->globalPos()) : release->globalPos());
++ QMouseEvent *newRelease = new QMouseEvent(release->type(),
++ releaseWindowPos, releaseWindowPos, release->screenPos(),
++ release->button(), release->buttons(),
++ release->modifiers(), release->source());
++ QCoreApplication::postEvent(o, newRelease);
+ return true; // defer mouse release events until drag event loop has returned
++ }
+ case QEvent::MouseButtonDblClick:
+ case QEvent::Wheel:
+ return true;
+@@ -349,7 +370,7 @@ static inline QPoint fromNativeGlobalPixels(const QPoint &point)
+ into account.
+ */
+
+-QSimpleDrag::QSimpleDrag() : m_current_window(0)
++QSimpleDrag::QSimpleDrag()
+ {
+ }
+
+@@ -373,6 +394,7 @@ void QSimpleDrag::startDrag()
+ updateCursor(Qt::IgnoreAction);
+ }
+ setExecutedDropAction(Qt::IgnoreAction);
++ qCDebug(lcDnd) << "drag began from" << m_current_window<< "cursor pos" << QCursor::pos() << "can drop?" << canDrop();
+ }
+
+ void QSimpleDrag::cancel()
+diff --git a/src/gui/kernel/qsimpledrag_p.h b/src/gui/kernel/qsimpledrag_p.h
+index 0b8a0bc703..bbd7f7f4bb 100644
+--- a/src/gui/kernel/qsimpledrag_p.h
++++ b/src/gui/kernel/qsimpledrag_p.h
+@@ -105,6 +105,9 @@ protected:
+
+ QDrag *drag() const { return m_drag; }
+
++protected:
++ QWindow *m_current_window;
++
+ private:
+ void enableEventFilter();
+ void disableEventFilter();
+@@ -132,9 +135,6 @@ protected:
+ virtual void cancel() Q_DECL_OVERRIDE;
+ virtual void move(const QPoint &globalPos) Q_DECL_OVERRIDE;
+ virtual void drop(const QPoint &globalPos) Q_DECL_OVERRIDE;
+-
+-private:
+- QWindow *m_current_window;
+ };
+
+ #endif // QT_NO_DRAGANDDROP
+--
+cgit v1.1-6-g87c4
+
+
diff --git a/source/l/qt5/patches/qt5.qtbug-69310.patch b/source/l/qt5/patches/qt5.qtbug-69310.patch
new file mode 100644
index 00000000..b9246273
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-69310.patch
@@ -0,0 +1,37 @@
+From fcba9fa861574f33e1d2e54d8c8d6da8062927cd Mon Sep 17 00:00:00 2001
+From: Allan Sandfeld Jensen <allan.jensen@qt.io>
+Date: Wed, 23 Jan 2019 10:42:12 +0100
+Subject: Fix regression in QPlainTextEdit updating
+
+It was incorrectly counting a block having more than one line as having
+changed visibility.
+
+Fixes: QTBUG-69310
+Change-Id: I502cda1d3e8a4efb1c14122353cc0a4731d8581c
+Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
+---
+ src/widgets/widgets/qplaintextedit.cpp | 7 ++++---
+ 1 file changed, 4 insertions(+), 3 deletions(-)
+
+diff --git a/src/widgets/widgets/qplaintextedit.cpp b/src/widgets/widgets/qplaintextedit.cpp
+index d6f6a364a8..57f2dec8f7 100644
+--- a/src/widgets/widgets/qplaintextedit.cpp
++++ b/src/widgets/widgets/qplaintextedit.cpp
+@@ -312,10 +312,11 @@ void QPlainTextDocumentLayout::documentChanged(int from, int charsRemoved, int c
+ QTextBlock block = changeStartBlock;
+ do {
+ block.clearLayout();
+- const int lineCount = block.isVisible() ? 1 : 0;
+- if (block.lineCount() != lineCount) {
++ if (block.isVisible()
++ ? (block.lineCount() == 0)
++ : (block.lineCount() > 0)) {
+ blockVisibilityChanged = true;
+- block.setLineCount(lineCount);
++ block.setLineCount(block.isVisible() ? 1 : 0);
+ }
+ if (block == changeEndBlock)
+ break;
+--
+cgit v1.2.1
+
diff --git a/source/l/qt5/patches/qt5.qtbug-76255.patch b/source/l/qt5/patches/qt5.qtbug-76255.patch
new file mode 100644
index 00000000..678913ce
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-76255.patch
@@ -0,0 +1,35 @@
+From cc32a691936f37eaaec618a71edd62f896009c9d Mon Sep 17 00:00:00 2001
+From: Joerg Bornemann <joerg.bornemann@qt.io>
+Date: Fri, 06 Sep 2019 10:54:44 +0200
+Subject: [PATCH] Fix CMake config files for -libdir different from "lib"
+
+When Qt was configured with -libdir different from "lib", one could not
+build with CMake whenever a static lib was pulled in (e.g. uitools).
+
+Do not hard-code "/lib" but use the correct variable also for static
+libraries.
+
+Fixes: QTBUG-76255
+Change-Id: I28c6861752e29e461247628d2b1f8a9ec32f0790
+Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
+Reviewed-by: Fabian Vogt <fabian@ritter-vogt.de>
+---
+
+diff --git a/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in b/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
+index d4fd057..f4a34d6 100644
+--- a/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
++++ b/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
+@@ -53,7 +53,11 @@
+ set(_lib_deps)
+ set(_link_flags)
+
+- get_filename_component(_qt5_install_libs \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/lib\" ABSOLUTE)
++!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
++ set(_qt5_install_libs \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}\")
++!!ELSE
++ set(_qt5_install_libs \"$${CMAKE_LIB_DIR}\")
++!!ENDIF
+
+ if(EXISTS \"${prl_file_location}\")
+ file(STRINGS \"${prl_file_location}\" _prl_strings REGEX \"QMAKE_PRL_LIBS_FOR_CMAKE[ \\t]*=\")
+
diff --git a/source/l/qt5/patches/qt5.qtbug-77037.patch b/source/l/qt5/patches/qt5.qtbug-77037.patch
new file mode 100644
index 00000000..4dac59a9
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-77037.patch
@@ -0,0 +1,89 @@
+From 0b57f15958f07ef12c8944d6db7a33a6fe9d9c59 Mon Sep 17 00:00:00 2001
+From: Allan Sandfeld Jensen <allan.jensen@qt.io>
+Date: Mon, 23 Sep 2019 13:49:53 +0200
+Subject: Fix building with pulseaudio 13
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+The function signature changed though the ABI stayed the same.
+
+Change-Id: I86ca361b5e4f0c523e1031910df438c23beee876
+Fixes: QTBUG-77037
+Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>
+---
+ chromium/media/audio/pulse/pulse.sigs | 16 ++++++++--------
+ chromium/media/audio/pulse/pulse_stub_header.fragment | 11 +++++++++++
+ 2 files changed, 19 insertions(+), 8 deletions(-)
+
+diff --git a/chromium/media/audio/pulse/pulse.sigs b/chromium/media/audio/pulse/pulse.sigs
+index 8b5888786a9..daaeb149c13 100644
+--- a/chromium/media/audio/pulse/pulse.sigs
++++ b/chromium/media/audio/pulse/pulse.sigs
+@@ -24,11 +24,11 @@ pa_operation* pa_context_get_source_info_by_index(pa_context* c, uint32_t idx, p
+ pa_operation* pa_context_get_source_info_by_name(pa_context* c, const char* name, pa_source_info_cb_t cb, void *userdata);
+ pa_operation* pa_context_get_source_info_list(pa_context* c, pa_source_info_cb_t cb, void* userdata);
+ pa_operation* pa_context_get_sink_info_list(pa_context* c, pa_sink_info_cb_t cb, void* userdata);
+-pa_context_state_t pa_context_get_state(pa_context* c);
++pa_context_state_t pa_context_get_state(const_pa_context_ptr c);
+ pa_context* pa_context_new(pa_mainloop_api* mainloop, const char* name);
+ pa_operation* pa_context_set_source_volume_by_index(pa_context* c, uint32_t idx, const pa_cvolume* volume, pa_context_success_cb_t cb, void* userdata);
+ void pa_context_set_state_callback(pa_context* c, pa_context_notify_cb_t cb, void* userdata);
+-pa_operation_state_t pa_operation_get_state(pa_operation* o);
++pa_operation_state_t pa_operation_get_state(const_pa_operation_ptr o);
+ void pa_context_unref(pa_context* c);
+ void pa_operation_unref(pa_operation* o);
+ int pa_stream_begin_write(pa_stream* p, void** data, size_t* nbytes);
+@@ -38,23 +38,23 @@ pa_operation* pa_stream_cork(pa_stream* s, int b, pa_stream_success_cb_t cb, voi
+ int pa_stream_disconnect(pa_stream* s);
+ int pa_stream_drop(pa_stream *p);
+ pa_operation* pa_stream_flush(pa_stream* s, pa_stream_success_cb_t cb, void* userdata);
+-uint32_t pa_stream_get_device_index(pa_stream* s);
++uint32_t pa_stream_get_device_index(const_pa_stream_ptr s);
+ int pa_stream_get_latency(pa_stream* s, pa_usec_t* r_usec, int* negative);
+-pa_stream_state_t pa_stream_get_state(pa_stream* p);
++pa_stream_state_t pa_stream_get_state(const_pa_stream_ptr p);
+ pa_stream* pa_stream_new(pa_context* c, const char* name, const pa_sample_spec* ss, const pa_channel_map * map);
+ pa_stream* pa_stream_new_with_proplist(pa_context* c, const char* name, const pa_sample_spec* ss, const pa_channel_map* map, pa_proplist* p);
+ pa_proplist* pa_proplist_new(void);
+-int pa_proplist_contains(pa_proplist* p, const char* key);
++int pa_proplist_contains(const_pa_proplist_ptr p, const char* key);
+ void pa_proplist_free(pa_proplist* p);
+-const char* pa_proplist_gets(pa_proplist* p, const char* key);
++const char* pa_proplist_gets(const_pa_proplist_ptr p, const char* key);
+ int pa_proplist_sets(pa_proplist* p, const char* key, const char* value);
+-size_t pa_stream_readable_size(pa_stream *p);
++size_t pa_stream_readable_size(const_pa_stream_ptr p);
+ int pa_stream_peek(pa_stream* p, const void** data, size_t* nbytes);
+ void pa_stream_set_read_callback(pa_stream* p, pa_stream_request_cb_t cb, void* userdata);
+ void pa_stream_set_state_callback(pa_stream* s, pa_stream_notify_cb_t cb, void* userdata);
+ int pa_stream_write(pa_stream* p, const void* data, size_t nbytes, pa_free_cb_t free_cb, int64_t offset, pa_seek_mode_t seek);
+ void pa_stream_set_write_callback(pa_stream *p, pa_stream_request_cb_t cb, void *userdata);
+ void pa_stream_unref(pa_stream* s);
+-int pa_context_errno(pa_context *c);
++int pa_context_errno(const_pa_context_ptr c);
+ const char* pa_strerror(int error);
+ pa_cvolume* pa_cvolume_set(pa_cvolume* a, unsigned channels, pa_volume_t v);
+diff --git a/chromium/media/audio/pulse/pulse_stub_header.fragment b/chromium/media/audio/pulse/pulse_stub_header.fragment
+index 2a2d3e7552b..cdaa841b29f 100644
+--- a/chromium/media/audio/pulse/pulse_stub_header.fragment
++++ b/chromium/media/audio/pulse/pulse_stub_header.fragment
+@@ -5,4 +5,15 @@ extern "C" {
+
+ #include <pulse/pulseaudio.h>
+
++#if PA_MAJOR > 12
++typedef const pa_context* const_pa_context_ptr;
++typedef const pa_operation* const_pa_operation_ptr;
++typedef const pa_proplist* const_pa_proplist_ptr;
++typedef const pa_stream* const_pa_stream_ptr;
++#else
++typedef pa_context* const_pa_context_ptr;
++typedef pa_operation* const_pa_operation_ptr;
++typedef pa_proplist* const_pa_proplist_ptr;
++typedef pa_stream* const_pa_stream_ptr;
++#endif
+ }
+--
+cgit v1.2.1
+
diff --git a/source/l/qt5/patches/qt5.qtbug-77364.patch b/source/l/qt5/patches/qt5.qtbug-77364.patch
new file mode 100644
index 00000000..088856c7
--- /dev/null
+++ b/source/l/qt5/patches/qt5.qtbug-77364.patch
@@ -0,0 +1,13 @@
+diff --git a/src/widgets/kernel/qwidget.cpp b/src/widgets/kernel/qwidget.cpp
+index 04290a4ce1..27773d5762 100644
+--- a/src/widgets/kernel/qwidget.cpp
++++ b/src/widgets/kernel/qwidget.cpp
+@@ -6446,7 +6446,7 @@ void QWidget::setFocusProxy(QWidget * w)
+
+ if (changingAppFocusWidget) {
+ QWidget *newDeepestFocusProxy = d_func()->deepestFocusProxy();
+- QApplicationPrivate::focus_widget = newDeepestFocusProxy ? newDeepestFocusProxy : this;
++ QApplicationPrivate::setFocusWidget(newDeepestFocusProxy ? newDeepestFocusProxy : this, Qt::NoFocusReason);
+ }
+ }
+
diff --git a/source/l/qt5/patches/qt5.webengine_gcc8.patch b/source/l/qt5/patches/qt5.webengine_gcc8.patch
new file mode 100644
index 00000000..cf276bc7
--- /dev/null
+++ b/source/l/qt5/patches/qt5.webengine_gcc8.patch
@@ -0,0 +1,26 @@
+# Prevent these errors caused by using GCC8
+# (original patch taken from Fedora's chromium SRPM):
+#
+# make: *** [Makefile:1028: module-qtwebengine-make_first] Error 2
+# FAILED: obj/mojo/public/c/system/system/thunks.o
+# ../../3rdparty/chromium/mojo/public/c/system/buffer.h:38:42: error: static assertion failed: int64_t has weird alignment
+# ../../3rdparty/chromium/mojo/public/c/system/data_pipe.h:49:42: error: static assertion failed: int64_t has weird alignment
+# ../../3rdparty/chromium/mojo/public/c/system/message_pipe.h:47:42: error: static assertion failed: int64_t has weird alignment
+#
+--- a/src/3rdparty/chromium/mojo/public/c/system/macros.h 2018-05-15 14:58:46.448912634 -0400
++++ b/src/3rdparty/chromium/mojo/public/c/system/macros.h 2018-05-15 14:58:52.041784613 -0400
+@@ -18,7 +18,13 @@
+ #endif
+
+ // Like the C++11 |alignof| operator.
+-#if __cplusplus >= 201103L
++#if defined(__GNUC__) && __GNUC__ >= 8
++// GCC 8 has changed the alignof operator to return the minimal alignment
++// required by the target ABI, instead of the preferred alignment.
++// This means that on 32-bit x86, it will return 4 instead of 8.
++// Use __alignof__ instead to avoid this.
++#define MOJO_ALIGNOF(type) __alignof__(type)
++#elif __cplusplus >= 201103L
+ #define MOJO_ALIGNOF(type) alignof(type)
+ #elif defined(__GNUC__)
+ #define MOJO_ALIGNOF(type) __alignof__(type)
diff --git a/source/l/qt5/patches/qt5.whandle.patch b/source/l/qt5/patches/qt5.whandle.patch
new file mode 100644
index 00000000..4428974d
--- /dev/null
+++ b/source/l/qt5/patches/qt5.whandle.patch
@@ -0,0 +1,24 @@
+From: Ulf Hermann <ulf.hermann@theqtcompany.com>
+Date: Tue, 27 Oct 2015 14:25:42 +0000 (+0100)
+Subject: WIP: Also do hide/show via WA_OutsideWSRange for native widgets
+X-Git-Url: https://codereview.qt-project.org/gitweb?p=qt%2Fqtbase.git;a=commitdiff_plain;h=5ea44d1d516f0c68a6793279df5c1569ef9fadd2
+
+WIP: Also do hide/show via WA_OutsideWSRange for native widgets
+
+Task-number: QTBUG-48321
+Change-Id: I78ef29975181ee22429c9bd4b11d96d9e68b7a9c
+---
+
+diff --git a/qtbase/src/widgets/kernel/qwidget.cpp b/qtbase/src/widgets/kernel/qwidget.cpp
+index a006246..024005d 100644
+--- a/qtbase/src/widgets/kernel/qwidget.cpp
++++ b/qtbase/src/widgets/kernel/qwidget.cpp
+@@ -7169,7 +7169,7 @@ void QWidgetPrivate::setGeometry_sys(int x, int y, int w, int h, bool isMove)
+
+ bool needsShow = false;
+
+- if (q->isWindow()) {
++ if (q->isWindow() || q->windowHandle()) {
+ if (!(data.window_state & Qt::WindowFullScreen) && (w == 0 || h == 0)) {
+ q->setAttribute(Qt::WA_OutsideWSRange, true);
+ if (q->isVisible() && q->testAttribute(Qt::WA_Mapped))
diff --git a/source/l/qt5/patches/qtbase-qxcbwindow.patch b/source/l/qt5/patches/qtbase-qxcbwindow.patch
new file mode 100644
index 00000000..62a0bb44
--- /dev/null
+++ b/source/l/qt5/patches/qtbase-qxcbwindow.patch
@@ -0,0 +1,97 @@
+Taken from: https://code.qt.io/cgit/qt/qtbase.git/patch/?id=0c183117
+
+From 0c1831178540462da31fd7a4b6d2e446bc84498b Mon Sep 17 00:00:00 2001
+From: Erik Kurzinger <ekurzinger@nvidia.com>
+Date: Thu, 13 Jun 2019 08:15:50 -0700
+Subject: Track swap interval in QXcbWindow
+
+As per GLX_EXT_swap_control, the GLX swap interval is specified on a
+per-drawable basis. However, QGLXContext only tracks it per-context
+using the m_swapInterval member. If a new drawable is made current to a
+context, it is still necessary to call glXSwapIntervalEXT to change the
+swap interval, even if it has been previously called for the same
+context with a different drawable. However, currently,
+QGLXContext::makeCurrent doesn't do this if its m_swapInterval field
+matches the new swap interval. This change removes m_swapInterval from
+QGLXContext, instead tracking it in QXcbWindow. This still avoids
+unnecessary calls to glXSwapIntervalEXT, while ensuring the swap
+interval is always set for new window drawables.
+
+Change-Id: Idc34101476c6af618059f6f3d8925dee743994a3
+Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
+Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
+---
+ .../platforms/xcb/gl_integrations/xcb_glx/qglxintegration.cpp | 6 +++---
+ src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.h | 1 -
+ src/plugins/platforms/xcb/qxcbwindow.h | 4 ++++
+ 3 files changed, 7 insertions(+), 4 deletions(-)
+
+diff --git a/src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.cpp b/src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.cpp
+index 4adf662152..f26f698e76 100644
+--- a/src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.cpp
++++ b/src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.cpp
+@@ -204,7 +204,6 @@ QGLXContext::QGLXContext(QXcbScreen *screen, const QSurfaceFormat &format, QPlat
+ , m_shareContext(0)
+ , m_format(format)
+ , m_isPBufferCurrent(false)
+- , m_swapInterval(-1)
+ , m_ownsContext(nativeHandle.isNull())
+ , m_getGraphicsResetStatus(0)
+ , m_lost(false)
+@@ -567,9 +566,9 @@ bool QGLXContext::makeCurrent(QPlatformSurface *surface)
+
+ if (success && surfaceClass == QSurface::Window) {
+ int interval = surface->format().swapInterval();
++ QXcbWindow *window = static_cast<QXcbWindow *>(surface);
+ QXcbScreen *screen = screenForPlatformSurface(surface);
+- if (interval >= 0 && m_swapInterval != interval && screen) {
+- m_swapInterval = interval;
++ if (interval >= 0 && interval != window->swapInterval() && screen) {
+ typedef void (*qt_glXSwapIntervalEXT)(Display *, GLXDrawable, int);
+ typedef void (*qt_glXSwapIntervalMESA)(unsigned int);
+ static qt_glXSwapIntervalEXT glXSwapIntervalEXT = 0;
+@@ -588,6 +587,7 @@ bool QGLXContext::makeCurrent(QPlatformSurface *surface)
+ glXSwapIntervalEXT(m_display, glxDrawable, interval);
+ else if (glXSwapIntervalMESA)
+ glXSwapIntervalMESA(interval);
++ window->setSwapInterval(interval);
+ }
+ }
+
+diff --git a/src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.h b/src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.h
+index be9d3f5dcb..2a88fd6e59 100644
+--- a/src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.h
++++ b/src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.h
+@@ -87,7 +87,6 @@ private:
+ GLXContext m_shareContext;
+ QSurfaceFormat m_format;
+ bool m_isPBufferCurrent;
+- int m_swapInterval;
+ bool m_ownsContext;
+ GLenum (APIENTRY * m_getGraphicsResetStatus)();
+ bool m_lost;
+diff --git a/src/plugins/platforms/xcb/qxcbwindow.h b/src/plugins/platforms/xcb/qxcbwindow.h
+index f98cd8a74d..8258cc2dfa 100644
+--- a/src/plugins/platforms/xcb/qxcbwindow.h
++++ b/src/plugins/platforms/xcb/qxcbwindow.h
+@@ -184,6 +184,9 @@ public:
+ static void setWindowTitle(const QXcbConnection *conn, xcb_window_t window, const QString &title);
+ static QString windowTitle(const QXcbConnection *conn, xcb_window_t window);
+
++ int swapInterval() const { return m_swapInterval; }
++ void setSwapInterval(int swapInterval) { m_swapInterval = swapInterval; }
++
+ public Q_SLOTS:
+ void updateSyncRequestCounter();
+
+@@ -276,6 +279,7 @@ protected:
+ SyncState m_syncState = NoSyncNeeded;
+
+ QXcbSyncWindowRequest *m_pendingSyncRequest = nullptr;
++ int m_swapInterval = -1;
+ };
+
+ class QXcbForeignWindow : public QXcbWindow
+--
+cgit v1.2.1
+
diff --git a/source/l/qt5/patches/qtbase-zlib-compression.patch b/source/l/qt5/patches/qtbase-zlib-compression.patch
new file mode 100644
index 00000000..a6896a4d
--- /dev/null
+++ b/source/l/qt5/patches/qtbase-zlib-compression.patch
@@ -0,0 +1,41 @@
+Taken from: https://code.qt.io/cgit/qt/qtbase.git/patch/?id=cbdc9a77
+
+From cbdc9a7786278c31fdb6eb465f32d0374349c1ef Mon Sep 17 00:00:00 2001
+From: Thiago Macieira <thiago.macieira@intel.com>
+Date: Thu, 20 Jun 2019 09:36:46 -0700
+Subject: RCC: Change the default compression to Zlib
+
+Codebases using QResource::isCompressed() and assuming it is Zlib break
+if zstd is enabled. So change the default back to Zlib until Qt 6.0.
+
+[ChangeLog][Important Behavior Changes] RCC's default compression
+algorithm was changed back to Zlib, as it was in all previous releases
+until 5.13.0. The default will remain Zlib for all Qt 5.x releases but
+will change in Qt 6.0. To activate Zstd compression for your resources,
+either pass the --compress-algo=zstd option to the rcc tool or add the
+XML attribute compression-algorithm="zstd" to the <file> tags in the
+.qrc file.
+
+Task-number: QTBUG-76521
+Change-Id: Ief874765cd7b43798de3fffd15a9f56fd9ad1ad4
+Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
+---
+ src/tools/rcc/rcc.cpp | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/tools/rcc/rcc.cpp b/src/tools/rcc/rcc.cpp
+index 862e574f2d..011a7db810 100644
+--- a/src/tools/rcc/rcc.cpp
++++ b/src/tools/rcc/rcc.cpp
+@@ -58,7 +58,7 @@ enum {
+ CONSTANT_COMPRESSTHRESHOLD_DEFAULT = 70
+ };
+
+-#if QT_CONFIG(zstd)
++#if QT_CONFIG(zstd) && QT_VERSION >= QT_VERSION_CHECK(6,0,0)
+ # define CONSTANT_COMPRESSALGO_DEFAULT RCCResourceLibrary::CompressionAlgorithm::Zstd
+ #elif !defined(QT_NO_COMPRESS)
+ # define CONSTANT_COMPRESSALGO_DEFAULT RCCResourceLibrary::CompressionAlgorithm::Zlib
+--
+cgit v1.2.1
+
diff --git a/source/l/qt5/profile.d/qt5.csh b/source/l/qt5/profile.d/qt5.csh
new file mode 100644
index 00000000..ec1ecd9b
--- /dev/null
+++ b/source/l/qt5/profile.d/qt5.csh
@@ -0,0 +1,17 @@
+#!/bin/csh
+# Environment path variables for the Qt package:
+if ( ! $?QT5DIR ) then
+ # It's best to use the generic directory to avoid
+ # compiling in a version-containing path:
+ if ( -d /usr/lib@LIBDIRSUFFIX@/qt5 ) then
+ setenv QT5DIR /usr/lib@LIBDIRSUFFIX@/qt5
+ else
+ # Find the newest Qt directory and set $QT5DIR to that:
+ foreach qtd ( /usr/lib@LIBDIRSUFFIX@/qt5-* )
+ if ( -d $qtd ) then
+ setenv QT5DIR $qtd
+ endif
+ end
+ endif
+endif
+set path = ( $path $QT5DIR/bin )
diff --git a/source/l/qt5/profile.d/qt5.sh b/source/l/qt5/profile.d/qt5.sh
new file mode 100644
index 00000000..8ee075e1
--- /dev/null
+++ b/source/l/qt5/profile.d/qt5.sh
@@ -0,0 +1,17 @@
+#!/bin/sh
+# Environment variables for the Qt package.
+#
+# It's best to use the generic directory to avoid
+# compiling in a version-containing path:
+if [ -d /usr/lib@LIBDIRSUFFIX@/qt5 ]; then
+ QT5DIR=/usr/lib@LIBDIRSUFFIX@/qt5
+else
+ # Find the newest Qt directory and set $QT5DIR to that:
+ for qtd in /usr/lib@LIBDIRSUFFIX@/qt5-* ; do
+ if [ -d $qtd ]; then
+ QT5DIR=$qtd
+ fi
+ done
+fi
+PATH="$PATH:$QT5DIR/bin"
+export QT5DIR
diff --git a/source/l/qt5/qt5.SlackBuild b/source/l/qt5/qt5.SlackBuild
new file mode 100755
index 00000000..9ffabd27
--- /dev/null
+++ b/source/l/qt5/qt5.SlackBuild
@@ -0,0 +1,341 @@
+#!/bin/sh
+
+# Copyright 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Patrick J. Volkerding, Sebeka, MN, USA
+# All rights reserved.
+#
+# Redistribution and use of this script, with or without modification, is
+# permitted provided that the following conditions are met:
+#
+# 1. Redistributions of this script must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+# Merged some ideas from Alex Sarmardzic's script for qt4 at SlackBuilds.org
+# ^^ Modified by Robby Workman <rworkman@slackware.com> for QT4 & KDE4
+#
+# Modifications 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019 Eric Hameleers, Eindhoven, NL
+# Modifications for qt 5.2.0 2013 by Michael James, AU
+# Modifications for qt 5.x by Eric Hameleers, Eindhoven, NL
+
+cd $(dirname $0) ; CWD=$(pwd)
+
+PKGNAM=qt5
+VERSION=$(ls qt-*.tar.?z | rev | cut -f 3- -d . | cut -f 1 -d - | rev)
+BUILD=${BUILD:-1}
+PKGSRC=$(echo $VERSION | cut -d - -f 1)
+PKGVER=$(echo $VERSION | tr - _)
+
+# Automatically determine the architecture we're building on:
+if [ -z "$ARCH" ]; then
+ case "$(uname -m)" in
+ i?86) ARCH=i586 ;;
+ arm*) readelf /usr/bin/file -A | egrep -q "Tag_CPU.*[4,5]" && ARCH=arm || ARCH=armv7hl ;;
+ # Unless $ARCH is already set, use uname -m for all other archs:
+ *) ARCH=$(uname -m) ;;
+ esac
+ export ARCH
+fi
+
+# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
+# the name of the created package would be, and then exit. This information
+# could be useful to other scripts.
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PKGNAM-${PKGVER}-${ARCH}-${BUILD}.txz"
+ exit 0
+fi
+
+if [ "$ARCH" = "i486" ]; then
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+ SLKLDFLAGS=""
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i586" ]; then
+ SLKCFLAGS="-O2 -march=i586 -mtune=i686"
+ SLKLDFLAGS=""
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "s390" ]; then
+ SLKCFLAGS="-O2"
+ SLKLDFLAGS=""
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ SLKLDFLAGS=""
+ SLKLDFLAGS="-L/usr/lib64"
+ LIBDIRSUFFIX="64"
+elif [ "$ARCH" = "armv7hl" ]; then
+ # To prevent "qatomic_armv6.h error: output number 2 not directly addressable"
+ # More permanent solution is to patch gcc:
+ # http://bazaar.launchpad.net/~linaro-toolchain-dev/gcc-linaro/4.6/revision/106731
+ SLKCFLAGS="-O2 -march=armv7-a -mfpu=vfpv3-d16 -fno-strict-volatile-bitfields"
+ SLKLDFLAGS=""
+ LIBDIRSUFFIX=""
+else
+ SLKCFLAGS="-O2"
+ SLKLDFLAGS=""
+ LIBDIRSUFFIX=""
+fi
+
+case "$ARCH" in
+ arm*) TARGET=$ARCH-slackware-linux-gnueabi ;;
+ *) TARGET=$ARCH-slackware-linux ;;
+esac
+
+NUMJOBS=${NUMJOBS:-" -j$(expr $(nproc) + 1) "}
+
+TMP=${TMP:-/tmp}
+PKG=$TMP/package-${PKGNAM}
+
+rm -rf $PKG
+mkdir -p $TMP $PKG
+cd $TMP
+rm -rf qt-everywhere-src-$VERSION
+echo "Extracting qt-everywhere-src-$VERSION.tar.xz"
+tar xf $CWD/qt-everywhere-src-$VERSION.tar.xz || exit 1
+cd qt-everywhere-src-$PKGSRC || exit 1
+
+chown -R root:root .
+find . \
+ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
+ -exec chmod 755 {} \+ -o \
+ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
+ -exec chmod 644 {} \+
+
+# Use -reduce-relocations only on i?86 and x86_64 architextures.
+# https://bugreports.qt-project.org/browse/QTBUG-36129
+if echo $ARCH | grep -q '\(i.86\|x86_64\)' 2>/dev/null; then
+ RELOCATIONS="-reduce-relocations"
+else
+ RELOCATIONS=""
+fi
+
+# Fix path to mysql header:
+cat $CWD/patches/qt5.mysql.h.diff | patch -p1 --verbose || exit 1
+
+# CMake generates wrong -isystem /usr/include compilations flags with Qt5::Gui
+# and for it breaks KWin compilation with:
+# /usr/include/c++/9.1.0/cstdlib:75:15: fatal error: stdlib.h: No such file or directory
+# See also https://bugzilla.redhat.com/1704474
+cd qtbase
+ cat $CWD/patches/qt5.qtbase_cmake_isystem_includes.patch \
+ | patch -p1 --verbose || exit 1
+cd - 1>/dev/null
+
+# CVE-2020-0569 (fixed in 5.14.0):
+cd qtbase
+ cat $CWD/patches/qt5.cve-2020-0569.patch \
+ | patch -p1 --verbose || exit 1
+cd - 1>/dev/null
+
+# CVE-2020-0570 (fixed in 5.14.1):
+cd qtbase
+ cat $CWD/patches/qt5.cve-2020-0570.patch \
+ | patch -p1 --verbose || exit 1
+cd - 1>/dev/null
+
+if ! pkg-config --exists libpulse 2>/dev/null ; then
+ # Forcibly disable pulseaudio in qtwebengine:
+ cat $CWD/patches/qt5.pulseaudio.diff | patch -p1 --verbose || exit 1
+ # Disable pulseaudio in Qt5:
+ PACONF="-no-pulseaudio"
+else
+ PACONF=" "
+fi
+
+# Use our custom compiler and linker flags:
+sed -e "s|^\(QMAKE_CFLAGS_RELEASE.*\)|\1 ${SLKCFLAGS}|" \
+ -i qtbase/mkspecs/common/gcc-base.conf || exit 1
+sed -e "s|^\(QMAKE_LFLAGS_RELEASE.*\)|\1 ${SLKLDFLAGS}|" \
+ -i qtbase/mkspecs/common/g++-unix.conf || exit 1
+
+export CFLAGS="$SLKCFLAGS"
+export CXXFLAGS="$SLKCFLAGS"
+export OPENSOURCE_CXXFLAGS="$SLKCFLAGS"
+export QTDIR="${TMP}/qt-everywhere-src-${PKGSRC}"
+export LD_LIBRARY_PATH="${QTDIR}/qtbase/lib:${QTDIR}/qttools/lib:${LD_LIBRARY_PATH}"
+export QT_PLUGIN_PATH="${QTDIR}/qtbase/plugins"
+./configure -v \
+ -confirm-license \
+ -opensource \
+ -prefix /usr \
+ -libdir /usr/lib${LIBDIRSUFFIX} \
+ -bindir /usr/lib${LIBDIRSUFFIX}/qt5/bin \
+ -sysconfdir /etc/xdg \
+ -headerdir /usr/include/qt5 \
+ -datadir /usr/share/qt5 \
+ -archdatadir /usr/lib${LIBDIRSUFFIX}/qt5 \
+ -docdir /usr/doc/qt5-$PKGVER \
+ -examplesdir /usr/doc/qt5-$PKGVER/examples \
+ -proprietary-codecs \
+ -system-libpng \
+ -system-libjpeg \
+ -system-sqlite \
+ -system-zlib \
+ -plugin-sql-mysql \
+ -plugin-sql-sqlite \
+ -accessibility \
+ -alsa \
+ -dbus \
+ -glib \
+ -icu \
+ -opengl \
+ -openssl-linked \
+ -optimized-qmake \
+ -qpa xcb \
+ -qt-harfbuzz \
+ -verbose \
+ -xcb \
+ -nomake examples \
+ -nomake tests \
+ -no-mimetype-database \
+ -no-separate-debug-info \
+ -no-strip \
+ -no-use-gold-linker \
+ -webengine-proprietary-codecs \
+ ${PACONF} \
+ ${RELOCATIONS} \
+ -no-pch \
+ # No-precompiled-headers is ccache-friendly.
+
+# Sometimes a failure happens when parallelizing make. Try again if make fails,
+# but make a failure the second time around (single threaded) a fatal error:
+make $NUMJOBS || make || exit 1
+make install INSTALL_ROOT=$PKG || exit 1
+
+# Strip binaries the Slackware way:
+find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \
+ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+
+# Remove rpaths:
+for file in $(find . | xargs file | grep -e "executable" -e "shared object" | grep ELF | cut -f 1 -d : 2> /dev/null) ; do
+ if [ ! "$(patchelf --print-rpath $file 2> /dev/null)" = "" ]; then
+ patchelf --remove-rpath $file
+ fi
+done
+
+# Don't ship .la files:
+rm -f $PKG/usr/lib${LIBDIRSUFFIX}/*.la
+
+# Fix internal linking for Qt5WebEngineCore.pc ,
+# thanks to Larry Hajali's SBo script:
+sed -i \
+ -e 's|-Wl,--start-group.* -Wl,--end-group||' \
+ -e "s|-L${PWD}/qtwebengine/src/core/api/Release||" \
+ $PKG/usr/lib${LIBDIRSUFFIX}/pkgconfig/Qt5WebEngineCore.pc
+
+# Fix the path in prl files:
+find "$PKG/usr/lib${LIBDIRSUFFIX}" -type f -name '*.prl' \
+ -exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' {} \;
+
+# Fix the qmake path in pri file:
+sed -i "s,${QTDIR}/qtbase,/usr/lib${LIBDIRSUFFIX}/qt5," \
+ $PKG/usr/lib${LIBDIRSUFFIX}/qt5/mkspecs/modules/qt_lib_bootstrap_private.pri
+
+# Install symlinks to the Qt5 binaries in the $PATH:
+mkdir -p $PKG/usr/bin
+for FILE in $PKG/usr/lib${LIBDIRSUFFIX}/qt5/bin/* ; do
+ ln -s ../lib${LIBDIRSUFFIX}/qt5/bin/$(basename $FILE) $PKG/usr/bin/$(basename $FILE)-qt5
+done
+
+# Set the QT5DIR variable in the environment:
+mkdir -p $PKG/etc/profile.d
+sed -e "s,@LIBDIRSUFFIX@,${LIBDIRSUFFIX},g" $CWD/profile.d/$PKGNAM.sh \
+ > $PKG/etc/profile.d/$PKGNAM.sh
+sed -e "s,@LIBDIRSUFFIX@,${LIBDIRSUFFIX},g" $CWD/profile.d/$PKGNAM.csh \
+ > $PKG/etc/profile.d/$PKGNAM.csh
+chmod 0755 $PKG/etc/profile.d/*
+
+# Add menu entries for all those hidden but great Qt applications:
+# Qt5 logo:
+mkdir -p $PKG/usr/share/icons/hicolor/48x48/apps
+convert qtdoc/doc/src/images/qt-logo.png -resize 48x48 $PKG/usr/share/icons/hicolor/48x48/apps/qt5-logo.png
+# Assistant icons
+install -p -m644 -D qttools/src/assistant/assistant/images/assistant.png $PKG/usr/share/icons/hicolor/32x32/apps/qt5-assistant.png
+install -p -m644 -D qttools/src/assistant/assistant/images/assistant-128.png $PKG/usr/share/icons/hicolor/128x128/apps/qt5-assistant.png
+# Designer icon
+install -p -m644 -D qttools/src/designer/src/designer/images/designer.png $PKG/usr/share/icons/hicolor/128x128/apps/qt5-designer.png
+# QDbusViewer icons
+install -p -m644 qttools/src/qdbus/qdbusviewer/images/qdbusviewer.png $PKG/usr/share/icons/hicolor/32x32/apps/qt5-qdbusviewer.png
+install -p -m644 qttools/src/qdbus/qdbusviewer/images/qdbusviewer-128.png $PKG/usr/share/icons/hicolor/128x128/apps/qt5-qdbusviewer.png
+# Linguist icons
+for icon in qttools/src/linguist/linguist/images/icons/linguist-*-32.png ; do
+ size=$(echo $(basename ${icon}) | cut -d- -f2)
+ install -p -m644 -D ${icon} $PKG/usr/share/icons/hicolor/${size}x${size}/apps/qt5-linguist.png
+done
+
+# And the .desktop files too:
+mkdir -p $PKG/usr/share/applications
+cat <<EOF > $PKG/usr/share/applications/qt5-designer.desktop
+[Desktop Entry]
+Name=Qt5 Designer
+GenericName=Interface Designer
+Comment=Design GUIs for Qt5 applications
+Exec=designer-qt5
+Icon=qt5-designer
+MimeType=application/x-designer;
+Terminal=false
+Encoding=UTF-8
+Type=Application
+Categories=Qt;Development;
+EOF
+cat <<EOF > $PKG/usr/share/applications/qt5-assistant.desktop
+[Desktop Entry]
+Name=Qt5 Assistant
+Comment=Shows Qt5 documentation and examples
+Exec=assistant-qt5
+Icon=qt5-assistant
+Terminal=false
+Encoding=UTF-8
+Type=Application
+Categories=Qt;Development;Documentation;
+EOF
+cat <<EOF > $PKG/usr/share/applications/qt5-linguist.desktop
+[Desktop Entry]
+Name=Qt5 Linguist
+Comment=Add translations to Qt5 applications
+Exec=linguist-qt5
+Icon=qt5-linguist
+MimeType=text/vnd.trolltech.linguist;application/x-linguist;
+Terminal=false
+Encoding=UTF-8
+Type=Application
+Categories=Qt;Development;
+EOF
+cat <<EOF > $PKG/usr/share/applications/qt5-qdbusviewer.desktop
+[Desktop Entry]
+Name=Qt5 QDbusViewer
+GenericName=Qt5 D-Bus Debugger
+Comment=Debug D-Bus applications
+Exec=qdbusviewer-qt5
+Icon=qt5-qdbusviewer
+Terminal=false
+Type=Application
+Categories=Qt;Development;Debugger;
+EOF
+
+# Add a documentation directory:
+mkdir -p $PKG/usr/doc/$PKGNAM-$PKGVER
+cp -a \
+ README qtbase/{header*,LGPL_EXCEPTION.txt,LICENSE*} \
+ $PKG/usr/doc/$PKGNAM-$PKGVER
+if [ -d $PKG/usr/lib${LIBDIRSUFFIX}/qt5/doc/html ]; then
+ ( cd $PKG/usr/doc/$PKGNAM-$PKGVER
+ ln -sf /usr/lib${LIBDIRSUFFIX}/qt5/doc/html .
+ )
+fi
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+cat $CWD/doinst.sh > $PKG/install/doinst.sh
+
+cd $PKG
+/sbin/makepkg -l y -c n $TMP/$PKGNAM-$PKGVER-$ARCH-$BUILD.txz
+
diff --git a/source/l/qt5/slack-desc b/source/l/qt5/slack-desc
new file mode 100644
index 00000000..d9b24602
--- /dev/null
+++ b/source/l/qt5/slack-desc
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description. Line
+# up the first '|' above the ':' following the base package name, and the '|'
+# on the right side marks the last column you can put a character in. You must
+# make exactly 11 lines for the formatting to be correct. It's also
+# customary to leave one space after the ':'.
+
+ |-----handy-ruler------------------------------------------------------|
+qt5: qt5 (a multi-platform C++ graphical user interface toolkit)
+qt5:
+qt5: Qt is a complete and well-developed object-oriented framework for
+qt5: developing graphical user interface (GUI) applications using C++.
+qt5:
+qt5: Homepage: http://www.qt.io/
+qt5:
+qt5:
+qt5:
+qt5:
+qt5:
diff --git a/source/n/openssh/openssh.tcp_wrappers.diff b/source/n/openssh/openssh.tcp_wrappers.diff
index 38e3b3b4..60c7c14e 100644
--- a/source/n/openssh/openssh.tcp_wrappers.diff
+++ b/source/n/openssh/openssh.tcp_wrappers.diff
@@ -1,6 +1,6 @@
---- ./configure.ac.orig 2019-04-17 17:52:57.000000000 -0500
-+++ ./configure.ac 2019-04-18 15:13:25.404941727 -0500
-@@ -1494,6 +1494,62 @@
+--- ./configure.ac.orig 2020-02-13 18:40:54.000000000 -0600
++++ ./configure.ac 2020-02-14 19:28:45.566081482 -0600
+@@ -1532,6 +1532,62 @@
AC_MSG_RESULT([no])
fi
@@ -63,7 +63,7 @@
# Check whether user wants to use ldns
LDNS_MSG="no"
AC_ARG_WITH(ldns,
-@@ -5245,6 +5301,7 @@
+@@ -5389,6 +5445,7 @@
echo " OSF SIA support: $SIA_MSG"
echo " KerberosV support: $KRB5_MSG"
echo " SELinux support: $SELINUX_MSG"
@@ -71,22 +71,23 @@
echo " MD5 password support: $MD5_MSG"
echo " libedit support: $LIBEDIT_MSG"
echo " libldns support: $LDNS_MSG"
---- ./sshd.c.orig 2019-04-17 17:52:57.000000000 -0500
-+++ ./sshd.c 2019-04-18 15:13:25.406941726 -0500
-@@ -122,6 +122,12 @@
- #include "auth-options.h"
- #include "version.h"
+--- ./sshd.c.orig 2020-02-13 18:40:54.000000000 -0600
++++ ./sshd.c 2020-02-14 19:30:12.694084273 -0600
+@@ -124,6 +124,13 @@
#include "ssherr.h"
+ #include "sk-api.h"
+
+#ifdef LIBWRAP
+#include <tcpd.h>
+#include <syslog.h>
+int allow_severity;
+int deny_severity;
+#endif /* LIBWRAP */
-
++
/* Re-exec fds */
#define REEXEC_DEVCRYPTO_RESERVED_FD (STDERR_FILENO + 1)
-@@ -2022,6 +2028,26 @@
+ #define REEXEC_STARTUP_PIPE_FD (STDERR_FILENO + 2)
+@@ -2107,6 +2114,26 @@
the_active_state = ssh;
ssh_packet_set_server(ssh);
@@ -113,9 +114,9 @@
check_ip_options(ssh);
/* Prepare the channels layer */
---- ./sshd.8.orig 2019-04-17 17:52:57.000000000 -0500
-+++ ./sshd.8 2019-04-18 15:13:25.407941726 -0500
-@@ -873,6 +873,12 @@
+--- ./sshd.8.orig 2020-02-13 18:40:54.000000000 -0600
++++ ./sshd.8 2020-02-14 19:28:45.574081482 -0600
+@@ -893,6 +893,12 @@
This file should be writable only by the user, and need not be
readable by anyone else.
.Pp
@@ -128,7 +129,7 @@
.It Pa /etc/hosts.equiv
This file is for host-based authentication (see
.Xr ssh 1 ) .
-@@ -975,6 +981,7 @@
+@@ -995,6 +1001,7 @@
.Xr ssh-keygen 1 ,
.Xr ssh-keyscan 1 ,
.Xr chroot 2 ,
diff --git a/source/n/openssh/openssh.url b/source/n/openssh/openssh.url
new file mode 100644
index 00000000..9c8a0cea
--- /dev/null
+++ b/source/n/openssh/openssh.url
@@ -0,0 +1 @@
+https://ftp.openbsd.org/pub/OpenBSD/OpenSSH/portable/
diff --git a/source/x/mesa/0001-swr-Fix-GCC-4.9-checks.patch b/source/x/mesa/0001-swr-Fix-GCC-4.9-checks.patch
new file mode 100644
index 00000000..03542cc4
--- /dev/null
+++ b/source/x/mesa/0001-swr-Fix-GCC-4.9-checks.patch
@@ -0,0 +1,58 @@
+From 4656d2d30a8c176d81f31827302cd082eff59de3 Mon Sep 17 00:00:00 2001
+From: Vinson Lee <vlee@freedesktop.org>
+Date: Sat, 1 Feb 2020 01:12:32 -0800
+Subject: [PATCH] swr: Fix GCC 4.9 checks.
+
+Fixes: f0a22956be48 ("swr/rast: _mm*_undefined_* implementations for gcc<4.9")
+Fixes: e21fc2c62527 ("swr/rast: non-regex knob fallback code for gcc < 4.9")
+Signed-off-by: Vinson Lee <vlee@freedesktop.org>
+Reviewed-by: Jan Zielinski <jan.zielinski@intel.com>
+(cherry picked from commit deb2bbf57ec1d0660dd85b7080bf5ebeb10e8768)
+---
+ .pick_status.json | 2 +-
+ .../drivers/swr/rasterizer/codegen/templates/gen_knobs.cpp | 2 +-
+ src/gallium/drivers/swr/rasterizer/common/os.h | 2 +-
+ 3 files changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/.pick_status.json b/.pick_status.json
+index a442be492f4..af4f23fb12f 100644
+--- a/.pick_status.json
++++ b/.pick_status.json
+@@ -319,7 +319,7 @@
+ "description": "swr: Fix GCC 4.9 checks.",
+ "nominated": true,
+ "nomination_type": 1,
+- "resolution": 0,
++ "resolution": 1,
+ "master_sha": null,
+ "because_sha": "f0a22956be4802e01f2b4f3244f011212626f12d"
+ },
+diff --git a/src/gallium/drivers/swr/rasterizer/codegen/templates/gen_knobs.cpp b/src/gallium/drivers/swr/rasterizer/codegen/templates/gen_knobs.cpp
+index 1ef83ad10d1..b073f73e3a0 100644
+--- a/src/gallium/drivers/swr/rasterizer/codegen/templates/gen_knobs.cpp
++++ b/src/gallium/drivers/swr/rasterizer/codegen/templates/gen_knobs.cpp
+@@ -43,7 +43,7 @@
+ //========================================================
+ void KnobBase::autoExpandEnvironmentVariables(std::string& text)
+ {
+-#if (__GNUC__) && (GCC_VERSION < 409000)
++#if (__GNUC__) && (GCC_VERSION < 40900)
+ // <regex> isn't implemented prior to gcc-4.9.0
+ // unix style variable replacement
+ size_t start;
+diff --git a/src/gallium/drivers/swr/rasterizer/common/os.h b/src/gallium/drivers/swr/rasterizer/common/os.h
+index e812da39851..7d33f6d99d6 100644
+--- a/src/gallium/drivers/swr/rasterizer/common/os.h
++++ b/src/gallium/drivers/swr/rasterizer/common/os.h
+@@ -182,7 +182,7 @@ static INLINE void _mm256_storeu2_m128i(__m128i* hi, __m128i* lo, __m256i a)
+ }
+
+ // gcc prior to 4.9 doesn't have _mm*_undefined_*
+-#if (__GNUC__) && (GCC_VERSION < 409000)
++#if (__GNUC__) && (GCC_VERSION < 40900)
+ #define _mm_undefined_si128 _mm_setzero_si128
+ #define _mm256_undefined_ps _mm256_setzero_ps
+ #endif
+--
+2.25.0
+
diff --git a/source/x/mesa/mesa.SlackBuild b/source/x/mesa/mesa.SlackBuild
index a3cf4ae3..a987721f 100755
--- a/source/x/mesa/mesa.SlackBuild
+++ b/source/x/mesa/mesa.SlackBuild
@@ -1,6 +1,6 @@
#!/bin/bash
-# Copyright 2006, 2007, 2008, 2009, 2010, 2011, 2013, 2014, 2015, 2016, 2017, 2018, 2019 Patrick J. Volkerding, Sebeka, MN, USA
+# Copyright 2006, 2007, 2008, 2009, 2010, 2011, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Patrick J. Volkerding, Sebeka, MN, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -23,9 +23,9 @@
cd $(dirname $0) ; CWD=$(pwd)
PKGNAM=mesa
-VERSION=${VERSION:-$(echo $PKGNAM-1*.tar.xz | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
+VERSION=${VERSION:-$(echo $PKGNAM-[0-9]*.tar.?z | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
DEMOVERS=${DEMOVERS:-8.4.0}
-BUILD=${BUILD:-1}
+BUILD=${BUILD:-2}
BUILD_DEMOS=${BUILD_DEMOS:-YES}
NUMJOBS=${NUMJOBS:-" -j$(expr $(nproc) + 1) "}
@@ -77,7 +77,7 @@ mkdir -p $TMP $PKG
cd $TMP
rm -rf ${PKGNAM}-${VERSION}
-tar xvf $CWD/${PKGNAM}-${VERSION}.tar.xz || exit 1
+tar xvf $CWD/${PKGNAM}-${VERSION}.tar.?z || exit 1
cd ${PKGNAM}-$VERSION || exit 1
# Let's kill the warning about operating on a dangling symlink:
@@ -101,6 +101,9 @@ if /bin/ls $CWD/patches/*.patch 1> /dev/null 2> /dev/null ; then
done
fi
+# Revert a patch causing illegal instruction crashes starting X:
+zcat $CWD/0001-swr-Fix-GCC-4.9-checks.patch.gz | patch -R -p1 --verbose || exit 1
+
# Configure, build, and install:
export CFLAGS="$SLKCFLAGS"
export CXXFLAGS="$SLKCFLAGS"