summaryrefslogtreecommitdiff
path: root/gnu/packages/patches
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/packages/patches')
-rw-r--r--gnu/packages/patches/bind-CVE-2018-5738.patch100
-rw-r--r--gnu/packages/patches/file-CVE-2017-1000249.patch27
-rw-r--r--gnu/packages/patches/fltk-shared-lib-defines.patch51
-rw-r--r--gnu/packages/patches/fltk-xfont-on-demand.patch45
-rw-r--r--gnu/packages/patches/ghostscript-CVE-2018-10194.patch52
-rw-r--r--gnu/packages/patches/mariadb-gcc-ice.patch24
-rw-r--r--gnu/packages/patches/monero-use-system-miniupnpc.patch111
-rw-r--r--gnu/packages/patches/openbabel-fix-crash-on-nwchem-output.patch34
-rw-r--r--gnu/packages/patches/openscenegraph-ffmpeg3.patch156
-rw-r--r--gnu/packages/patches/pyqt-public-sip.patch55
-rw-r--r--gnu/packages/patches/python-cairocffi-dlopen-path.patch10
-rw-r--r--gnu/packages/patches/quassel-qt-5.11.patch72
-rw-r--r--gnu/packages/patches/rust-bootstrap-stage0-test.patch55
-rw-r--r--gnu/packages/patches/rust-coresimd-doctest.patch21
-rw-r--r--gnu/packages/patches/sddm-fix-build-with-qt-5.11-1024.patch28
-rwxr-xr-xgnu/packages/patches/twinkle-include-qregexpvalidator.patch123
-rw-r--r--gnu/packages/patches/x265-arm-asm-primitives.patch360
-rw-r--r--gnu/packages/patches/xapian-revert-5489fb2f8.patch23
-rw-r--r--gnu/packages/patches/xorg-server-rotate-fb.patch35
19 files changed, 903 insertions, 479 deletions
diff --git a/gnu/packages/patches/bind-CVE-2018-5738.patch b/gnu/packages/patches/bind-CVE-2018-5738.patch
deleted file mode 100644
index ddef014651..0000000000
--- a/gnu/packages/patches/bind-CVE-2018-5738.patch
+++ /dev/null
@@ -1,100 +0,0 @@
-Fix CVE-2018-5738:
-
-https://kb.isc.org/article/AA-01616/0/CVE-2018-5738
-https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-5738
-
-diff --git a/bin/named/server.c b/bin/named/server.c
-index f63554e..847c4ff 100644
---- a/bin/named/server.c
-+++ b/bin/named/server.c
-@@ -3725,10 +3725,6 @@ configure_view(dns_view_t *view, dns_viewlist_t *viewlist,
- CHECKM(named_config_getport(config, &port), "port");
- dns_view_setdstport(view, port);
-
-- CHECK(configure_view_acl(vconfig, config, named_g_config,
-- "allow-query", NULL, actx,
-- named_g_mctx, &view->queryacl));
--
- /*
- * Make the list of response policy zone names for a view that
- * is used for real lookups and so cares about hints.
-@@ -4692,21 +4688,35 @@ configure_view(dns_view_t *view, dns_viewlist_t *viewlist,
- "allow-query-cache-on", NULL, actx,
- named_g_mctx, &view->cacheonacl));
- /*
-- * Set "allow-query-cache", "allow-recursion", and
-- * "allow-recursion-on" acls if configured in named.conf.
-- * (Ignore the global defaults for now, because these ACLs
-- * can inherit from each other when only some of them set at
-- * the options/view level.)
-+ * Set the "allow-query", "allow-query-cache", "allow-recursion",
-+ * and "allow-recursion-on" ACLs if configured in named.conf, but
-+ * NOT from the global defaults. This is done by leaving the third
-+ * argument to configure_view_acl() NULL.
-+ *
-+ * We ignore the global defaults here because these ACLs
-+ * can inherit from each other. If any are still unset after
-+ * applying the inheritance rules, we'll look up the defaults at
-+ * that time.
- */
-- CHECK(configure_view_acl(vconfig, config, NULL, "allow-query-cache",
-- NULL, actx, named_g_mctx, &view->cacheacl));
-+
-+ /* named.conf only */
-+ CHECK(configure_view_acl(vconfig, config, NULL,
-+ "allow-query", NULL, actx,
-+ named_g_mctx, &view->queryacl));
-+
-+ /* named.conf only */
-+ CHECK(configure_view_acl(vconfig, config, NULL,
-+ "allow-query-cache", NULL, actx,
-+ named_g_mctx, &view->cacheacl));
-
- if (strcmp(view->name, "_bind") != 0 &&
- view->rdclass != dns_rdataclass_chaos)
- {
-+ /* named.conf only */
- CHECK(configure_view_acl(vconfig, config, NULL,
- "allow-recursion", NULL, actx,
- named_g_mctx, &view->recursionacl));
-+ /* named.conf only */
- CHECK(configure_view_acl(vconfig, config, NULL,
- "allow-recursion-on", NULL, actx,
- named_g_mctx, &view->recursiononacl));
-@@ -4744,18 +4754,21 @@ configure_view(dns_view_t *view, dns_viewlist_t *viewlist,
- * the global config.
- */
- if (view->recursionacl == NULL) {
-+ /* global default only */
- CHECK(configure_view_acl(NULL, NULL, named_g_config,
- "allow-recursion", NULL,
- actx, named_g_mctx,
- &view->recursionacl));
- }
- if (view->recursiononacl == NULL) {
-+ /* global default only */
- CHECK(configure_view_acl(NULL, NULL, named_g_config,
- "allow-recursion-on", NULL,
- actx, named_g_mctx,
- &view->recursiononacl));
- }
- if (view->cacheacl == NULL) {
-+ /* global default only */
- CHECK(configure_view_acl(NULL, NULL, named_g_config,
- "allow-query-cache", NULL,
- actx, named_g_mctx,
-@@ -4769,6 +4782,14 @@ configure_view(dns_view_t *view, dns_viewlist_t *viewlist,
- CHECK(dns_acl_none(mctx, &view->cacheacl));
- }
-
-+ if (view->queryacl == NULL) {
-+ /* global default only */
-+ CHECK(configure_view_acl(NULL, NULL, named_g_config,
-+ "allow-query", NULL,
-+ actx, named_g_mctx,
-+ &view->queryacl));
-+ }
-+
- /*
- * Ignore case when compressing responses to the specified
- * clients. This causes case not always to be preserved,
diff --git a/gnu/packages/patches/file-CVE-2017-1000249.patch b/gnu/packages/patches/file-CVE-2017-1000249.patch
deleted file mode 100644
index 505acf1592..0000000000
--- a/gnu/packages/patches/file-CVE-2017-1000249.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-https://github.com/file/file/commit/35c94dc6acc418f1ad7f6241a6680e5327495793.patch
-http://openwall.com/lists/oss-security/2017/09/05/3
-
-The patch is minorly modified to apply to file-5.30
-
-From 35c94dc6acc418f1ad7f6241a6680e5327495793 Mon Sep 17 00:00:00 2001
-From: Christos Zoulas <christos@zoulas.com>
-Date: Sun, 27 Aug 2017 07:55:02 +0000
-Subject: [PATCH] Fix always true condition (Thomas Jarosch)
-
----
- src/readelf.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/readelf.c b/src/readelf.c
-index 81451827..5f425c97 100644
---- a/src/readelf.c
-+++ b/src/readelf.c
-@@ -511,7 +511,7 @@ do_bid_note(struct magic_set *ms, unsigned char *nbuf, uint32_t type,
- size_t noff, size_t doff, int *flags)
- {
- if (namesz == 4 && strcmp((char *)&nbuf[noff], "GNU") == 0 &&
-- type == NT_GNU_BUILD_ID && (descsz >= 4 || descsz <= 20)) {
-+ type == NT_GNU_BUILD_ID && (descsz >= 4 && descsz <= 20)) {
- uint8_t desc[20];
- const char *btype;
- uint32_t i;
diff --git a/gnu/packages/patches/fltk-shared-lib-defines.patch b/gnu/packages/patches/fltk-shared-lib-defines.patch
deleted file mode 100644
index d36a50ff5e..0000000000
--- a/gnu/packages/patches/fltk-shared-lib-defines.patch
+++ /dev/null
@@ -1,51 +0,0 @@
-This patch from upstream revision 10588.
-
---- fltk-1.3.3/src/Xutf8.h
-+++ fltk-1.3.3/src/Xutf8.h
-@@ -25,6 +25,7 @@
- #include <X11/Xlib.h>
- #include <X11/Xlocale.h>
- #include <X11/Xutil.h>
-+#include <FL/Fl_Export.H>
-
- typedef struct {
- int nb_font;
-@@ -98,8 +99,8 @@
- XUtf8FontStruct *font_set,
- unsigned int ucs);
-
--int
--XGetUtf8FontAndGlyph(
-+FL_EXPORT int
-+fl_XGetUtf8FontAndGlyph(
- XUtf8FontStruct *font_set,
- unsigned int ucs,
- XFontStruct **fnt,
---- fltk-1.3.3/src/gl_draw.cxx
-+++ fltk-1.3.3/src/gl_draw.cxx
-@@ -114,7 +114,7 @@
- for (int i = 0; i < 0x400; i++) {
- XFontStruct *font = NULL;
- unsigned short id;
-- XGetUtf8FontAndGlyph(gl_fontsize->font, ii, &font, &id);
-+ fl_XGetUtf8FontAndGlyph(gl_fontsize->font, ii, &font, &id);
- if (font) glXUseXFont(font->fid, id, 1, gl_fontsize->listbase+ii);
- ii++;
- }
---- fltk-1.3.3/src/xutf8/utf8Wrap.c
-+++ fltk-1.3.3/src/xutf8/utf8Wrap.c
-@@ -816,10 +816,10 @@
- /** get the X font and glyph ID of a UCS char **/
- /*****************************************************************************/
- int
--XGetUtf8FontAndGlyph(XUtf8FontStruct *font_set,
-- unsigned int ucs,
-- XFontStruct **fnt,
-- unsigned short *id) {
-+fl_XGetUtf8FontAndGlyph(XUtf8FontStruct *font_set,
-+ unsigned int ucs,
-+ XFontStruct **fnt,
-+ unsigned short *id) {
-
- /* int x; */
- int *encodings; /* encodings array */
diff --git a/gnu/packages/patches/fltk-xfont-on-demand.patch b/gnu/packages/patches/fltk-xfont-on-demand.patch
deleted file mode 100644
index cdcdd9af05..0000000000
--- a/gnu/packages/patches/fltk-xfont-on-demand.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-Fixes undefined reference to `Fl_XFont_On_Demand::value()'.
-From <http://www.fltk.org/str.php?L3156+P0+S0+C0+I0+E0+V1+QOn_Demand>.
-
-Index: src/fl_font.cxx
-===================================================================
---- fltk-1.3.3/src/fl_font.cxx (revision 10503)
-+++ fltk-1.3.3/src/fl_font.cxx (revision 10504)
-@@ -55,6 +55,12 @@
- # include "fl_font_x.cxx"
- #endif // WIN32
-
-+#if ! (defined(WIN32) || defined(__APPLE__))
-+XFontStruct *fl_X_core_font()
-+{
-+ return fl_xfont.value();
-+}
-+#endif
-
- double fl_width(const char* c) {
- if (c) return fl_width(c, (int) strlen(c));
-Index: src/gl_draw.cxx
-===================================================================
---- fltk-1.3.3/src/gl_draw.cxx (revision 10503)
-+++ fltk-1.3.3/src/gl_draw.cxx (revision 10504)
-@@ -81,7 +81,7 @@
- * then sorting through them at draw time (for normal X rendering) to find which one can
- * render the current glyph... But for now, just use the first font in the list for GL...
- */
-- XFontStruct *font = fl_xfont;
-+ XFontStruct *font = fl_X_core_font();
- int base = font->min_char_or_byte2;
- int count = font->max_char_or_byte2-base+1;
- fl_fontsize->listbase = glGenLists(256);
-Index: FL/x.H
-===================================================================
---- fltk-1.3.3/FL/x.H (revision 10503)
-+++ fltk-1.3.3/FL/x.H (revision 10504)
-@@ -132,6 +132,7 @@
- XFontStruct *ptr;
- };
- extern FL_EXPORT Fl_XFont_On_Demand fl_xfont;
-+extern FL_EXPORT XFontStruct* fl_X_core_font();
-
- // this object contains all X-specific stuff about a window:
- // Warning: this object is highly subject to change!
diff --git a/gnu/packages/patches/ghostscript-CVE-2018-10194.patch b/gnu/packages/patches/ghostscript-CVE-2018-10194.patch
new file mode 100644
index 0000000000..242e57c27c
--- /dev/null
+++ b/gnu/packages/patches/ghostscript-CVE-2018-10194.patch
@@ -0,0 +1,52 @@
+Fix CVE-2018-10194:
+
+https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-10194
+https://bugs.ghostscript.com/show_bug.cgi?id=699255
+
+Patch copied from upstream source repository:
+
+https://git.ghostscript.com/?p=ghostpdl.git;a=commit;h=39b1e54b2968620723bf32e96764c88797714879
+
+From 39b1e54b2968620723bf32e96764c88797714879 Mon Sep 17 00:00:00 2001
+From: Ken Sharp <ken.sharp@artifex.com>
+Date: Wed, 18 Apr 2018 15:46:32 +0100
+Subject: [PATCH] pdfwrite - Guard against trying to output an infinite number
+
+Bug #699255 " Buffer overflow on pprintg1 due to mishandle postscript file data to pdf"
+
+The file uses an enormous parameter to xyxhow, causing an overflow in
+the calculation of text positioning (value > 1e39).
+
+Since this is basically a nonsense value, and PostScript only supports
+real values up to 1e38, this patch follows the same approach as for
+a degenerate CTM, and treats it as 0.
+
+Adobe Acrobat Distiller throws a limitcheck error, so we could do that
+instead if this approach proves to be a problem.
+---
+ devices/vector/gdevpdts.c | 7 ++++++-
+ 1 file changed, 6 insertions(+), 1 deletion(-)
+
+diff --git a/devices/vector/gdevpdts.c b/devices/vector/gdevpdts.c
+index 848ad781f..172fe6bc3 100644
+--- a/devices/vector/gdevpdts.c
++++ b/devices/vector/gdevpdts.c
+@@ -103,9 +103,14 @@ append_text_move(pdf_text_state_t *pts, double dw)
+ static int
+ set_text_distance(gs_point *pdist, double dx, double dy, const gs_matrix *pmat)
+ {
+- int code = gs_distance_transform_inverse(dx, dy, pmat, pdist);
++ int code;
+ double rounded;
+
++ if (dx > 1e38 || dy > 1e38)
++ code = gs_error_undefinedresult;
++ else
++ code = gs_distance_transform_inverse(dx, dy, pmat, pdist);
++
+ if (code == gs_error_undefinedresult) {
+ /* The CTM is degenerate.
+ Can't know the distance in user space.
+--
+2.18.0
+
diff --git a/gnu/packages/patches/mariadb-gcc-ice.patch b/gnu/packages/patches/mariadb-gcc-ice.patch
new file mode 100644
index 0000000000..59b188f45a
--- /dev/null
+++ b/gnu/packages/patches/mariadb-gcc-ice.patch
@@ -0,0 +1,24 @@
+Work around this GCC ICE: <https://bugs.gnu.org/31708>. It shows up
+only when doing native compiles on armhf-linux.
+
+--- mariadb-10.1.33/plugin/semisync/semisync_master.cc 2018-07-28 02:13:12.604020250 +0200
++++ mariadb-10.1.33/plugin/semisync/semisync_master.cc 2018-07-28 02:14:11.907753417 +0200
+@@ -847,6 +847,8 @@
+ return function_exit(kWho, 0);
+ }
+
++volatile const void *kSyncHeaderPtr = &ReplSemiSyncMaster::kSyncHeader;
++
+ int ReplSemiSyncMaster::reserveSyncHeader(unsigned char *header,
+ unsigned long size)
+ {
+@@ -873,7 +875,7 @@
+ /* Set the magic number and the sync status. By default, no sync
+ * is required.
+ */
+- memcpy(header, kSyncHeader, sizeof(kSyncHeader));
++ memcpy(header, (void *)kSyncHeaderPtr, sizeof(kSyncHeader));
+ hlen= sizeof(kSyncHeader);
+ }
+ return function_exit(kWho, hlen);
+
diff --git a/gnu/packages/patches/monero-use-system-miniupnpc.patch b/gnu/packages/patches/monero-use-system-miniupnpc.patch
new file mode 100644
index 0000000000..6bc825d121
--- /dev/null
+++ b/gnu/packages/patches/monero-use-system-miniupnpc.patch
@@ -0,0 +1,111 @@
+This reverts commit 1e20d705e7c64d2b17c031f345057d1e8850fafa, so that it's possible to use our own
+miniupnpc, instead of a git submodule.
+---
+ CMakeLists.txt | 8 ++++++++
+ external/CMakeLists.txt | 41 +++++++++++++++++++++++++++++++----------
+ src/p2p/net_node.inl | 13 ++++++++++---
+ 3 files changed, 49 insertions(+), 13 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 3b93988e..ef948885 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -430,6 +430,14 @@ include_directories("${CMAKE_CURRENT_BINARY_DIR}/translations")
+
+ add_subdirectory(external)
+
++# Final setup for miniupnpc
++if(UPNP_STATIC OR IOS)
++ add_definitions("-DUPNP_STATIC")
++else()
++ add_definitions("-DUPNP_DYNAMIC")
++ include_directories(${UPNP_INCLUDE})
++endif()
++
+ # Final setup for libunbound
+ include_directories(${UNBOUND_INCLUDE})
+ link_directories(${UNBOUND_LIBRARY_DIRS})
+diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt
+index 1fc4d64c..b4f712ee 100644
+--- a/external/CMakeLists.txt
++++ b/external/CMakeLists.txt
+@@ -34,21 +34,42 @@
+ # We always compile if we are building statically to reduce static dependency issues...
+ # ...except for FreeBSD, because FreeBSD is a special case that doesn't play well with
+ # others.
++if(NOT IOS)
++ find_package(Miniupnpc QUIET)
++endif()
+
+-find_package(Miniupnpc REQUIRED)
++# If we have the correct shared version and we're not building static, use it
++if(STATIC OR IOS)
++ set(USE_SHARED_MINIUPNPC false)
++elseif(MINIUPNP_FOUND AND MINIUPNPC_VERSION_1_7_OR_HIGHER)
++ set(USE_SHARED_MINIUPNPC true)
++endif()
+
+-message(STATUS "Using in-tree miniupnpc")
++if(USE_SHARED_MINIUPNPC)
++ message(STATUS "Using shared miniupnpc found at ${MINIUPNP_INCLUDE_DIR}")
+
+-add_subdirectory(miniupnp/miniupnpc)
++ set(UPNP_STATIC false PARENT_SCOPE)
++ set(UPNP_INCLUDE ${MINIUPNP_INCLUDE_DIR} PARENT_SCOPE)
++ set(UPNP_LIBRARIES ${MINIUPNP_LIBRARY} PARENT_SCOPE)
++else()
++ if(STATIC)
++ message(STATUS "Using miniupnpc from local source tree for static build")
++ else()
++ message(STATUS "Using miniupnpc from local source tree (/external/miniupnp/miniupnpc)")
++ endif()
+
+-set_property(TARGET libminiupnpc-static PROPERTY FOLDER "external")
+-if(MSVC)
+- set_property(TARGET libminiupnpc-static APPEND_STRING PROPERTY COMPILE_FLAGS " -wd4244 -wd4267")
+-elseif(NOT MSVC)
+- set_property(TARGET libminiupnpc-static APPEND_STRING PROPERTY COMPILE_FLAGS " -Wno-undef -Wno-unused-result -Wno-unused-value")
+-endif()
++ add_subdirectory(miniupnp/miniupnpc)
++
++ set_property(TARGET libminiupnpc-static PROPERTY FOLDER "external")
++ if(MSVC)
++ set_property(TARGET libminiupnpc-static APPEND_STRING PROPERTY COMPILE_FLAGS " -wd4244 -wd4267")
++ elseif(NOT MSVC)
++ set_property(TARGET libminiupnpc-static APPEND_STRING PROPERTY COMPILE_FLAGS " -Wno-undef -Wno-unused-result -Wno-unused-value")
++ endif()
+
+-set(UPNP_LIBRARIES "libminiupnpc-static" PARENT_SCOPE)
++ set(UPNP_STATIC true PARENT_SCOPE)
++ set(UPNP_LIBRARIES "libminiupnpc-static" PARENT_SCOPE)
++endif()
+
+ find_package(Unbound)
+
+diff --git a/src/p2p/net_node.inl b/src/p2p/net_node.inl
+index 9b21705e..76340a22 100644
+--- a/src/p2p/net_node.inl
++++ b/src/p2p/net_node.inl
+@@ -49,9 +49,16 @@
+ #include "storages/levin_abstract_invoke2.h"
+ #include "cryptonote_core/cryptonote_core.h"
+
+-#include <miniupnp/miniupnpc/miniupnpc.h>
+-#include <miniupnp/miniupnpc/upnpcommands.h>
+-#include <miniupnp/miniupnpc/upnperrors.h>
++// We have to look for miniupnpc headers in different places, dependent on if its compiled or external
++#ifdef UPNP_STATIC
++ #include <miniupnp/miniupnpc/miniupnpc.h>
++ #include <miniupnp/miniupnpc/upnpcommands.h>
++ #include <miniupnp/miniupnpc/upnperrors.h>
++#else
++ #include "miniupnpc.h"
++ #include "upnpcommands.h"
++ #include "upnperrors.h"
++#endif
+
+ #undef MONERO_DEFAULT_LOG_CATEGORY
+ #define MONERO_DEFAULT_LOG_CATEGORY "net.p2p"
+--
+2.16.2
+
diff --git a/gnu/packages/patches/openbabel-fix-crash-on-nwchem-output.patch b/gnu/packages/patches/openbabel-fix-crash-on-nwchem-output.patch
new file mode 100644
index 0000000000..879df026a1
--- /dev/null
+++ b/gnu/packages/patches/openbabel-fix-crash-on-nwchem-output.patch
@@ -0,0 +1,34 @@
+From 52cea818bf68f8a2d3c48d55d00c2f8b7da25e4c Mon Sep 17 00:00:00 2001
+From: Daniel Hogan <daniel.hogan@usask.ca>
+Date: Tue, 28 Mar 2017 22:21:18 -0600
+Subject: [PATCH] Remove delete statement.
+
+When from_scratch is true, coordinates is not allocated. A separate if
+statement was added to handle the case when from_scratch is true that
+does not try to free coordinates.
+---
+ src/formats/nwchemformat.cpp | 9 ++++++---
+ 1 file changed, 6 insertions(+), 3 deletions(-)
+
+diff --git a/src/formats/nwchemformat.cpp b/src/formats/nwchemformat.cpp
+index 6f625ad5b..79298555f 100644
+--- a/src/formats/nwchemformat.cpp
++++ b/src/formats/nwchemformat.cpp
+@@ -232,11 +232,14 @@ static const char* OPTIMIZATION_END_PATTERN = " Optimization converged";
+ break;
+ tokenize(vs,buffer);
+ }
+- if ((from_scratch)||(i != natoms))
+- {
++ if (from_scratch)
++ {
++ return;
++ }
++ if (i != natoms) {
+ delete[] coordinates;
+ return;
+- }
++ }
+ molecule->AddConformer(coordinates);
+ }
+
diff --git a/gnu/packages/patches/openscenegraph-ffmpeg3.patch b/gnu/packages/patches/openscenegraph-ffmpeg3.patch
deleted file mode 100644
index 02c04a5583..0000000000
--- a/gnu/packages/patches/openscenegraph-ffmpeg3.patch
+++ /dev/null
@@ -1,156 +0,0 @@
-Description: Replace deprecated FFmpeg API
-Author: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
-See <http://forum.openscenegraph.org/viewtopic.php?t=15832>.
---- a/src/osgPlugins/ffmpeg/FFmpegDecoderVideo.cpp
-+++ b/src/osgPlugins/ffmpeg/FFmpegDecoderVideo.cpp
-@@ -71,7 +71,7 @@ void FFmpegDecoderVideo::open(AVStream *
- findAspectRatio();
-
- // Find out whether we support Alpha channel
-- m_alpha_channel = (m_context->pix_fmt == PIX_FMT_YUVA420P);
-+ m_alpha_channel = (m_context->pix_fmt == AV_PIX_FMT_YUVA420P);
-
- // Find out the framerate
- m_frame_rate = av_q2d(stream->avg_frame_rate);
-@@ -91,20 +91,19 @@ void FFmpegDecoderVideo::open(AVStream *
- throw std::runtime_error("avcodec_open() failed");
-
- // Allocate video frame
-- m_frame.reset(avcodec_alloc_frame());
-+ m_frame.reset(av_frame_alloc());
-
- // Allocate converted RGB frame
-- m_frame_rgba.reset(avcodec_alloc_frame());
-- m_buffer_rgba[0].resize(avpicture_get_size(PIX_FMT_RGB24, width(), height()));
-+ m_frame_rgba.reset(av_frame_alloc());
-+ m_buffer_rgba[0].resize(avpicture_get_size(AV_PIX_FMT_RGB24, width(), height()));
- m_buffer_rgba[1].resize(m_buffer_rgba[0].size());
-
- // Assign appropriate parts of the buffer to image planes in m_frame_rgba
-- avpicture_fill((AVPicture *) (m_frame_rgba).get(), &(m_buffer_rgba[0])[0], PIX_FMT_RGB24, width(), height());
-+ avpicture_fill((AVPicture *) (m_frame_rgba).get(), &(m_buffer_rgba[0])[0], AV_PIX_FMT_RGB24, width(), height());
-
- // Override get_buffer()/release_buffer() from codec context in order to retrieve the PTS of each frame.
- m_context->opaque = this;
-- m_context->get_buffer = getBuffer;
-- m_context->release_buffer = releaseBuffer;
-+ m_context->get_buffer2 = getBuffer;
- }
-
-
-@@ -263,8 +262,8 @@ int FFmpegDecoderVideo::convert(AVPictur
- #ifdef USE_SWSCALE
- if (m_swscale_ctx==0)
- {
-- m_swscale_ctx = sws_getContext(src_width, src_height, (PixelFormat) src_pix_fmt,
-- src_width, src_height, (PixelFormat) dst_pix_fmt,
-+ m_swscale_ctx = sws_getContext(src_width, src_height, (AVPixelFormat) src_pix_fmt,
-+ src_width, src_height, (AVPixelFormat) dst_pix_fmt,
- /*SWS_BILINEAR*/ SWS_BICUBIC, NULL, NULL, NULL);
- }
-
-@@ -311,14 +310,14 @@ void FFmpegDecoderVideo::publishFrame(co
- AVPicture * const dst = (AVPicture *) m_frame_rgba.get();
-
- // Assign appropriate parts of the buffer to image planes in m_frame_rgba
-- avpicture_fill((AVPicture *) (m_frame_rgba).get(), &(m_buffer_rgba[m_writeBuffer])[0], PIX_FMT_RGB24, width(), height());
-+ avpicture_fill((AVPicture *) (m_frame_rgba).get(), &(m_buffer_rgba[m_writeBuffer])[0], AV_PIX_FMT_RGB24, width(), height());
-
- // Convert YUVA420p (i.e. YUV420p plus alpha channel) using our own routine
-
-- if (m_context->pix_fmt == PIX_FMT_YUVA420P)
-+ if (m_context->pix_fmt == AV_PIX_FMT_YUVA420P)
- yuva420pToRgba(dst, src, width(), height());
- else
-- convert(dst, PIX_FMT_RGB24, src, m_context->pix_fmt, width(), height());
-+ convert(dst, AV_PIX_FMT_RGB24, src, m_context->pix_fmt, width(), height());
-
- // Wait 'delay' seconds before publishing the picture.
- int i_delay = static_cast<int>(delay * 1000000 + 0.5);
-@@ -345,7 +344,7 @@ void FFmpegDecoderVideo::publishFrame(co
-
- void FFmpegDecoderVideo::yuva420pToRgba(AVPicture * const dst, AVPicture * const src, int width, int height)
- {
-- convert(dst, PIX_FMT_RGB24, src, m_context->pix_fmt, width, height);
-+ convert(dst, AV_PIX_FMT_RGB24, src, m_context->pix_fmt, width, height);
-
- const size_t bpp = 4;
-
-@@ -363,31 +362,28 @@ void FFmpegDecoderVideo::yuva420pToRgba(
- }
- }
-
--
--
--int FFmpegDecoderVideo::getBuffer(AVCodecContext * const context, AVFrame * const picture)
-+int FFmpegDecoderVideo::getBuffer(AVCodecContext * const context, AVFrame * const picture, int flags)
- {
-+ AVBufferRef *ref;
- const FFmpegDecoderVideo * const this_ = reinterpret_cast<const FFmpegDecoderVideo*>(context->opaque);
-
-- const int result = avcodec_default_get_buffer(context, picture);
-+ const int result = avcodec_default_get_buffer2(context, picture, flags);
- int64_t * p_pts = reinterpret_cast<int64_t*>( av_malloc(sizeof(int64_t)) );
-
- *p_pts = this_->m_packet_pts;
- picture->opaque = p_pts;
-
-+ ref = av_buffer_create((uint8_t *)picture->opaque, sizeof(int64_t), FFmpegDecoderVideo::freeBuffer, picture->buf[0], flags);
-+ picture->buf[0] = ref;
-+
- return result;
- }
-
--
--
--void FFmpegDecoderVideo::releaseBuffer(AVCodecContext * const context, AVFrame * const picture)
-+void FFmpegDecoderVideo::freeBuffer(void *opaque, uint8_t *data)
- {
-- if (picture != 0)
-- av_freep(&picture->opaque);
--
-- avcodec_default_release_buffer(context, picture);
-+ AVBufferRef *ref = (AVBufferRef *)opaque;
-+ av_buffer_unref(&ref);
-+ av_free(data);
- }
-
--
--
- } // namespace osgFFmpeg
---- a/src/osgPlugins/ffmpeg/FFmpegDecoderVideo.hpp
-+++ b/src/osgPlugins/ffmpeg/FFmpegDecoderVideo.hpp
-@@ -94,8 +94,8 @@ private:
- int src_pix_fmt, int src_width, int src_height);
-
-
-- static int getBuffer(AVCodecContext * context, AVFrame * picture);
-- static void releaseBuffer(AVCodecContext * context, AVFrame * picture);
-+ static int getBuffer(AVCodecContext * context, AVFrame * picture, int flags);
-+ static void freeBuffer(void * opaque, uint8_t *data);
-
- PacketQueue & m_packets;
- FFmpegClocks & m_clocks;
---- a/src/osgPlugins/ffmpeg/FFmpegParameters.cpp
-+++ b/src/osgPlugins/ffmpeg/FFmpegParameters.cpp
-@@ -19,7 +19,7 @@ extern "C"
- #include <libavutil/pixdesc.h>
- }
-
--inline PixelFormat osg_av_get_pix_fmt(const char *name) { return av_get_pix_fmt(name); }
-+inline AVPixelFormat osg_av_get_pix_fmt(const char *name) { return av_get_pix_fmt(name); }
-
-
- namespace osgFFmpeg {
---- a/src/osgPlugins/ffmpeg/FFmpegDecoderAudio.cpp 2016-02-18 21:25:39.627923629 +0000
-+++ b/src/osgPlugins/ffmpeg/FFmpegDecoderAudio.cpp 2016-02-18 21:26:17.071140100 +0000
-@@ -227,8 +227,7 @@
- if (avcodec_open2(m_context, p_codec, NULL) < 0)
- throw std::runtime_error("avcodec_open() failed");
-
-- m_context->get_buffer = avcodec_default_get_buffer;
-- m_context->release_buffer = avcodec_default_release_buffer;
-+ m_context->get_buffer2 = avcodec_default_get_buffer2;
-
- }
-
diff --git a/gnu/packages/patches/pyqt-public-sip.patch b/gnu/packages/patches/pyqt-public-sip.patch
new file mode 100644
index 0000000000..5ec45f032b
--- /dev/null
+++ b/gnu/packages/patches/pyqt-public-sip.patch
@@ -0,0 +1,55 @@
+https://sources.debian.org/data/main/p/pyqt5/5.11.2+dfsg-1/debian/patches/public_sip.diff
+
+From: Dmitry Shachnev <mitya57@debian.org>
+Date: Tue, 3 Jul 2018 09:46:42 +0300
+Subject: Use the public version of sip module
+
+Per https://www.debian.org/doc/debian-policy/#convenience-copies-of-code.
+---
+ configure.py | 19 +------------------
+ 1 file changed, 1 insertion(+), 18 deletions(-)
+
+diff --git a/configure.py b/configure.py
+index 7c48136..ca23f93 100644
+--- a/configure.py
++++ b/configure.py
+@@ -642,15 +642,6 @@ class TargetConfiguration:
+ "Unable to import enum. Please install the enum34 "
+ "package from PyPI.")
+
+- # Check there is a private copy of the sip module already installed.
+- try:
+- from PyQt5 import sip
+- except ImportError:
+- error(
+- "Unable to import PyQt5.sip. Make sure you have "
+- "configured SIP to create a private copy of the sip "
+- "module.")
+-
+ # Get the details of the Python interpreter library.
+ py_major = self.py_version >> 16
+ py_minor = (self.py_version >> 8) & 0x0ff
+@@ -2438,7 +2429,7 @@ def get_sip_flags(target_config):
+ the target configuration.
+ """
+
+- sip_flags = ['-n', 'PyQt5.sip']
++ sip_flags = ['-n', 'sip']
+
+ # If we don't check for signed interpreters, we exclude the 'VendorID'
+ # feature
+@@ -2914,14 +2905,6 @@ def check_sip(target_config):
+ target_config is the target configuration.
+ """
+
+- # Check there is a private copy of the sip module already installed.
+- try:
+- from PyQt5 import sip
+- except ImportError:
+- error(
+- "Unable to import PyQt5.sip. Make sure you have configured "
+- "SIP to create a private copy of the sip module.")
+-
+ if target_config.sip is None:
+ error(
+ "Make sure you have a working sip on your PATH or use the "
diff --git a/gnu/packages/patches/python-cairocffi-dlopen-path.patch b/gnu/packages/patches/python-cairocffi-dlopen-path.patch
new file mode 100644
index 0000000000..e7a7fe3737
--- /dev/null
+++ b/gnu/packages/patches/python-cairocffi-dlopen-path.patch
@@ -0,0 +1,10 @@
+--- cairocffi-0.8.0/cairocffi/__init__.py.orig 2018-07-16 11:00:59.075664158 +0200
++++ cairocffi-0.8.0/cairocffi/__init__.py 2018-07-16 17:09:42.471958015 +0200
+@@ -35,6 +35,7 @@
+ return lib
+ except OSError:
+ pass
++ return ffi.dlopen(name)
+ raise OSError("dlopen() failed to load a library: %s" % ' / '.join(names))
+
+
diff --git a/gnu/packages/patches/quassel-qt-5.11.patch b/gnu/packages/patches/quassel-qt-5.11.patch
deleted file mode 100644
index 545f8b7610..0000000000
--- a/gnu/packages/patches/quassel-qt-5.11.patch
+++ /dev/null
@@ -1,72 +0,0 @@
-https://github.com/quassel/quassel/commit/92f4dca367c3a6f0536a1e0f3fbb44bb6ed4da62.patch
-This can be removed after quassel 0.12.5.
-
-From 92f4dca367c3a6f0536a1e0f3fbb44bb6ed4da62 Mon Sep 17 00:00:00 2001
-From: Manuel Nickschas <sputnick@quassel-irc.org>
-Date: Thu, 3 May 2018 23:19:34 +0200
-Subject: [PATCH] cmake: Fix build with Qt 5.11
-
-Qt 5.11 removes the qt5_use_modules function, so add a copy. If
-present, the Qt-provided function will be used instead.
-
-Closes GH-355.
----
- cmake/QuasselMacros.cmake | 38 ++++++++++++++++++++++++++++++++++++++
- 1 file changed, 38 insertions(+)
-
-diff --git a/cmake/QuasselMacros.cmake b/cmake/QuasselMacros.cmake
-index 652c0042d..d77ba1cfb 100644
---- a/cmake/QuasselMacros.cmake
-+++ b/cmake/QuasselMacros.cmake
-@@ -5,6 +5,9 @@
- # The qt4_use_modules function was taken from CMake's Qt4Macros.cmake:
- # (C) 2005-2009 Kitware, Inc.
- #
-+# The qt5_use_modules function was taken from Qt 5.10.1 (and modified):
-+# (C) 2005-2011 Kitware, Inc.
-+#
- # Redistribution and use is allowed according to the terms of the BSD license.
- # For details see the accompanying COPYING-CMAKE-SCRIPTS file.
-
-@@ -43,6 +46,41 @@ function(qt4_use_modules _target _link_type)
- endforeach()
- endfunction()
-
-+# Qt 5.11 removed the qt5_use_modules function, so we need to provide it until we can switch to a modern CMake version.
-+# If present, the Qt-provided version will be used automatically instead.
-+function(qt5_use_modules _target _link_type)
-+ if (NOT TARGET ${_target})
-+ message(FATAL_ERROR "The first argument to qt5_use_modules must be an existing target.")
-+ endif()
-+ if ("${_link_type}" STREQUAL "LINK_PUBLIC" OR "${_link_type}" STREQUAL "LINK_PRIVATE" )
-+ set(_qt5_modules ${ARGN})
-+ set(_qt5_link_type ${_link_type})
-+ else()
-+ set(_qt5_modules ${_link_type} ${ARGN})
-+ endif()
-+
-+ if ("${_qt5_modules}" STREQUAL "")
-+ message(FATAL_ERROR "qt5_use_modules requires at least one Qt module to use.")
-+ endif()
-+ foreach(_module ${_qt5_modules})
-+ if (NOT Qt5${_module}_FOUND)
-+ find_package(Qt5${_module} PATHS "${_Qt5_COMPONENT_PATH}" NO_DEFAULT_PATH)
-+ if (NOT Qt5${_module}_FOUND)
-+ message(FATAL_ERROR "Can not use \"${_module}\" module which has not yet been found.")
-+ endif()
-+ endif()
-+ target_link_libraries(${_target} ${_qt5_link_type} ${Qt5${_module}_LIBRARIES})
-+ set_property(TARGET ${_target} APPEND PROPERTY INCLUDE_DIRECTORIES ${Qt5${_module}_INCLUDE_DIRS})
-+ set_property(TARGET ${_target} APPEND PROPERTY COMPILE_DEFINITIONS ${Qt5${_module}_COMPILE_DEFINITIONS})
-+ if (Qt5_POSITION_INDEPENDENT_CODE
-+ AND (CMAKE_VERSION VERSION_LESS 2.8.12
-+ AND (NOT CMAKE_CXX_COMPILER_ID STREQUAL "GNU"
-+ OR CMAKE_CXX_COMPILER_VERSION VERSION_LESS 5.0)))
-+ set_property(TARGET ${_target} PROPERTY POSITION_INDEPENDENT_CODE ${Qt5_POSITION_INDEPENDENT_CODE})
-+ endif()
-+ endforeach()
-+endfunction()
-+
- # Some wrappers for simplifying dual-Qt support
-
- function(qt_use_modules)
diff --git a/gnu/packages/patches/rust-bootstrap-stage0-test.patch b/gnu/packages/patches/rust-bootstrap-stage0-test.patch
new file mode 100644
index 0000000000..e8484903e5
--- /dev/null
+++ b/gnu/packages/patches/rust-bootstrap-stage0-test.patch
@@ -0,0 +1,55 @@
+Bootstrap tests failed with local stage0 cargo and rustc
+Backported changes from https://github.com/rust-lang/rust/pull/51977
+
+From 0834d9d771e912f51deca6c25699e44734624546 Mon Sep 17 00:00:00 2001
+From: Nikolai Merinov <nikolai.merinov@member.fsf.org>
+Date: Mon, 2 Jul 2018 01:45:35 +0500
+Subject: [PATCH] bootstrap: tests should use rustc from config.toml
+
+Tests should always use "rustc" and "cargo" from config.toml instead
+of assuming that stage0 binaries was downloaded to build directory.
+---
+ src/bootstrap/bootstrap.py | 2 ++
+ src/bootstrap/config.rs | 6 ++----
+ 2 files changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/src/bootstrap/bootstrap.py b/src/bootstrap/bootstrap.py
+index 487440becf..1701f7b83a 100644
+--- a/src/bootstrap/bootstrap.py
++++ b/src/bootstrap/bootstrap.py
+@@ -788,6 +788,8 @@ def bootstrap(help_triggered):
+ env["BOOTSTRAP_PARENT_ID"] = str(os.getpid())
+ env["BOOTSTRAP_PYTHON"] = sys.executable
+ env["BUILD_DIR"] = build.build_dir
++ env["CARGO"] = build.cargo()
++ env["RUSTC"] = build.rustc()
+ run(args, env=env, verbose=build.verbose)
+
+
+diff --git a/src/bootstrap/config.rs b/src/bootstrap/config.rs
+index 6dd6291be2..d1a0deb583 100644
+--- a/src/bootstrap/config.rs
++++ b/src/bootstrap/config.rs
+@@ -23,7 +23,6 @@ use std::cmp;
+
+ use num_cpus;
+ use toml;
+-use util::exe;
+ use cache::{INTERNER, Interned};
+ use flags::Flags;
+ pub use flags::Subcommand;
+@@ -362,9 +361,8 @@ impl Config {
+ config.src = Config::path_from_python("SRC");
+ config.out = Config::path_from_python("BUILD_DIR");
+
+- let stage0_root = config.out.join(&config.build).join("stage0/bin");
+- config.initial_rustc = stage0_root.join(exe("rustc", &config.build));
+- config.initial_cargo = stage0_root.join(exe("cargo", &config.build));
++ config.initial_rustc = Config::path_from_python("RUSTC");
++ config.initial_cargo = Config::path_from_python("CARGO");
+
+ config
+ }
+--
+2.17.1
+
diff --git a/gnu/packages/patches/rust-coresimd-doctest.patch b/gnu/packages/patches/rust-coresimd-doctest.patch
new file mode 100644
index 0000000000..bfa0ab224b
--- /dev/null
+++ b/gnu/packages/patches/rust-coresimd-doctest.patch
@@ -0,0 +1,21 @@
+Doctest coresimd::x86::__m256 failed on processors withouth "avx" feature.
+Backported patch with changes from https://github.com/rust-lang-nursery/stdsimd/issues/481
+
+--- rustc-1.26.2-src-orig/src/stdsimd/coresimd/x86/mod.rs 1970-01-01 05:00:00.000000000 +0500
++++ rustc-1.26.2-src/src/stdsimd/coresimd/x86/mod.rs 2018-06-22 00:01:55.142026720 +0500
+@@ -293,13 +293,13 @@
+ /// use std::arch::x86_64::*;
+ ///
+ /// # fn main() {
+- /// # #[target_feature(enable = "sse")]
++ /// # #[target_feature(enable = "avx")]
+ /// # unsafe fn foo() {
+ /// let eight_zeros = _mm256_setzero_ps();
+ /// let eight_ones = _mm256_set1_ps(1.0);
+ /// let eight_floats = _mm256_set_ps(1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0);
+ /// # }
+- /// # if is_x86_feature_detected!("sse") { unsafe { foo() } }
++ /// # if is_x86_feature_detected!("avx") { unsafe { foo() } }
+ /// # }
+ /// ```
+ pub struct __m256(f32, f32, f32, f32, f32, f32, f32, f32);
diff --git a/gnu/packages/patches/sddm-fix-build-with-qt-5.11-1024.patch b/gnu/packages/patches/sddm-fix-build-with-qt-5.11-1024.patch
deleted file mode 100644
index 53c184230a..0000000000
--- a/gnu/packages/patches/sddm-fix-build-with-qt-5.11-1024.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 2efc649..8903b52 100644
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -93,7 +95,7 @@
- find_package(XKB REQUIRED)
-
- # Qt 5
--find_package(Qt5 5.6.0 CONFIG REQUIRED Core DBus Gui Qml Quick LinguistTools)
-+find_package(Qt5 5.8.0 CONFIG REQUIRED Core DBus Gui Qml Quick LinguistTools Test)
-
- # find qt5 imports dir
- get_target_property(QMAKE_EXECUTABLE Qt5::qmake LOCATION)
-diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
-index c9d935a..bb85ddd 100644
---- a/test/CMakeLists.txt
-+++ b/test/CMakeLists.txt
-@@ -2,9 +2,8 @@
-
- include_directories(../src/common)
-
--
- set(ConfigurationTest_SRCS ConfigurationTest.cpp ../src/common/ConfigReader.cpp)
- add_executable(ConfigurationTest ${ConfigurationTest_SRCS})
- add_test(NAME Configuration COMMAND ConfigurationTest)
-
--qt5_use_modules(ConfigurationTest Test)
-+target_link_libraries(ConfigurationTest Qt5::Core Qt5::Test)
diff --git a/gnu/packages/patches/twinkle-include-qregexpvalidator.patch b/gnu/packages/patches/twinkle-include-qregexpvalidator.patch
new file mode 100755
index 0000000000..4096cc8712
--- /dev/null
+++ b/gnu/packages/patches/twinkle-include-qregexpvalidator.patch
@@ -0,0 +1,123 @@
+Copied from upstream:
+
+https://github.com/LubosD/twinkle/commit/4b42755619011c117a76bdf98e417ebedc47e319
+
+From 4b42755619011c117a76bdf98e417ebedc47e319 Mon Sep 17 00:00:00 2001
+From: Michal Kubecek <mkubecek@suse.cz>
+Date: Wed, 6 Jun 2018 10:07:21 +0200
+Subject: [PATCH] Include <QRegExpValidator> explicitly
+
+Since Qt 5.11, generated ui_getprofilename.h no longer includes QHeaderView
+which breaks the chain that included qvalidator.h in getprofilename.cpp.
+As it feels rather fragile to rely on such indirect includes, let's include
+<QRegExpValidator> explicitly in each file using QRegExpValidator class.
+---
+ src/gui/diamondcardprofileform.cpp | 1 +
+ src/gui/getprofilenameform.cpp | 2 +-
+ src/gui/inviteform.cpp | 1 +
+ src/gui/mphoneform.cpp | 1 +
+ src/gui/numberconversionform.cpp | 1 +
+ src/gui/syssettingsform.cpp | 1 +
+ src/gui/userprofileform.cpp | 1 +
+ src/gui/wizardform.cpp | 1 +
+ 8 files changed, 8 insertions(+), 1 deletion(-)
+
+diff --git a/src/gui/diamondcardprofileform.cpp b/src/gui/diamondcardprofileform.cpp
+index 6656909..517180b 100644
+--- a/src/gui/diamondcardprofileform.cpp
++++ b/src/gui/diamondcardprofileform.cpp
+@@ -21,6 +21,7 @@
+
+ #include <QRegExp>
+ #include <QValidator>
++#include <QRegExpValidator>
+ #include "gui.h"
+ #include "diamondcard.h"
+ #include "getprofilenameform.h"
+diff --git a/src/gui/getprofilenameform.cpp b/src/gui/getprofilenameform.cpp
+index 1319e1d..89c715e 100644
+--- a/src/gui/getprofilenameform.cpp
++++ b/src/gui/getprofilenameform.cpp
+@@ -1,7 +1,7 @@
+ #include "getprofilenameform.h"
+-
+ #include <QDir>
+ #include <QMessageBox>
++#include <QRegExpValidator>
+ #include "user.h"
+ #include "protocol.h"
+
+diff --git a/src/gui/inviteform.cpp b/src/gui/inviteform.cpp
+index 433fb22..2a5b68d 100644
+--- a/src/gui/inviteform.cpp
++++ b/src/gui/inviteform.cpp
+@@ -7,6 +7,7 @@
+ #include "sys_settings.h"
+ #include <QRegExp>
+ #include <QValidator>
++#include <QRegExpValidator>
+
+ /*
+ Copyright (C) 2005-2009 Michel de Boer <michel@twinklephone.com>
+diff --git a/src/gui/mphoneform.cpp b/src/gui/mphoneform.cpp
+index 260fda7..c4e3c1d 100644
+--- a/src/gui/mphoneform.cpp
++++ b/src/gui/mphoneform.cpp
+@@ -54,6 +54,7 @@
+ #include <QRegExp>
+ #include <QValidator>
+ #include <QSettings>
++#include <QRegExpValidator>
+ #include "buddyform.h"
+ #include "diamondcardprofileform.h"
+ #include "osd.h"
+diff --git a/src/gui/numberconversionform.cpp b/src/gui/numberconversionform.cpp
+index f8ae64c..8481a9b 100644
+--- a/src/gui/numberconversionform.cpp
++++ b/src/gui/numberconversionform.cpp
+@@ -1,5 +1,6 @@
+ #include "numberconversionform.h"
+
++#include <QRegExpValidator>
+ #include "gui.h"
+
+ /*
+diff --git a/src/gui/syssettingsform.cpp b/src/gui/syssettingsform.cpp
+index 216af54..355df59 100644
+--- a/src/gui/syssettingsform.cpp
++++ b/src/gui/syssettingsform.cpp
+@@ -28,6 +28,7 @@
+ #include "twinkle_config.h"
+ #include <QRegExp>
+ #include <QValidator>
++#include <QRegExpValidator>
+ #include "syssettingsform.h"
+ /*
+ * Constructs a SysSettingsForm as a child of 'parent', with the
+diff --git a/src/gui/userprofileform.cpp b/src/gui/userprofileform.cpp
+index 28700a6..9ed9209 100644
+--- a/src/gui/userprofileform.cpp
++++ b/src/gui/userprofileform.cpp
+@@ -31,6 +31,7 @@
+ #include <QStringList>
+ #include "twinkle_config.h"
+ #include <QListWidget>
++#include <QRegExpValidator>
+ #include "numberconversionform.h"
+ #include "util.h"
+ #include "userprofileform.h"
+diff --git a/src/gui/wizardform.cpp b/src/gui/wizardform.cpp
+index 777aa12..f925875 100644
+--- a/src/gui/wizardform.cpp
++++ b/src/gui/wizardform.cpp
+@@ -23,6 +23,7 @@
+ #include <QTextStream>
+ #include "gui.h"
+ #include <QFile>
++#include <QRegExpValidator>
+ #include "wizardform.h"
+
+ #define PROV_NONE QT_TRANSLATE_NOOP("WizardForm", "None (direct IP to IP calls)")
+--
+2.17.0
+
diff --git a/gnu/packages/patches/x265-arm-asm-primitives.patch b/gnu/packages/patches/x265-arm-asm-primitives.patch
new file mode 100644
index 0000000000..f49aafe577
--- /dev/null
+++ b/gnu/packages/patches/x265-arm-asm-primitives.patch
@@ -0,0 +1,360 @@
+From <https://git.busybox.net/buildroot/tree/package/x265/0003-arm-asm-primitives.patch?id=57d4a27eaf1a9e59d767c321e7b7500c5060a2ac>.
+This fixes build errors like:
+
+ cd /tmp/guix-build-x265-2.8.drv-0/x265_2.8/build/encoder && /gnu/store/cd5q2pni1d95fs3cdabbclyh9hqhw2nq-gcc-5.5.0/bin/c++ -DEXPORT_C_API=1 -DHAVE_ARMV6=1 -DHAVE_INT_TYPES_H=1 -DHAVE_NEON -DHIGH_BIT_DEPTH=0 -DX265_ARCH_ARM=1 -DX265_DEPTH=8 -DX265_NS=x265 -D__STDC_LIMIT_MACROS=1 -I/tmp/guix-build-x265-2.8.drv-0/x265_2.8/source/. -I/tmp/guix-build-x265-2.8.drv-0/x265_2.8/source/common -I/tmp/guix-build-x265-2.8.drv-0/x265_2.8/source/encoder -I/tmp/guix-build-x265-2.8.drv-0/x265_2.8/build -O2 -g -DNDEBUG -Wall -Wextra -Wshadow -std=gnu++98 -fPIC -mcpu=native -mfloat-abi=hard -mfpu=neon -marm -fPIC -Wno-array-bounds -ffast-math -fno-exceptions -Wno-uninitialized -o CMakeFiles/encoder.dir/search.cpp.o -c /tmp/guix-build-x265-2.8.drv-0/x265_2.8/source/encoder/search.cpp
+ /tmp/guix-build-x265-2.8.drv-0/x265_2.8/source/common/arm/asm-primitives.cpp:437:38: error: incompatible types in assignment of ?void(const pixel*, intptr_t, int16_t*, intptr_t) {aka void(const unsigned char*, int, short int*, int)}? to ?void (* [2])(const pixel*, intptr_t, int16_t*, intptr_t) {aka void (* [2])(const unsigned char*, int, short int*, int)}?
+ p.pu[LUMA_64x48].convert_p2s = PFX(filterPixelToShort_64x48_neon);
+ ^
+
+Downloaded from upstream bug report:
+https://bitbucket.org/multicoreware/x265/issues/406
+
+Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
+
+--- ./source/common/arm/asm-primitives.cpp.orig 2018-05-21 02:33:10.000000000 -0600
++++ ./source/common/arm/asm-primitives.cpp 2018-05-28 20:38:37.302378303 -0600
+@@ -48,77 +48,77 @@ void setupAssemblyPrimitives(EncoderPrim
+ p.ssim_4x4x2_core = PFX(ssim_4x4x2_core_neon);
+
+ // addAvg
+- p.pu[LUMA_4x4].addAvg = PFX(addAvg_4x4_neon);
+- p.pu[LUMA_4x8].addAvg = PFX(addAvg_4x8_neon);
+- p.pu[LUMA_4x16].addAvg = PFX(addAvg_4x16_neon);
+- p.pu[LUMA_8x4].addAvg = PFX(addAvg_8x4_neon);
+- p.pu[LUMA_8x8].addAvg = PFX(addAvg_8x8_neon);
+- p.pu[LUMA_8x16].addAvg = PFX(addAvg_8x16_neon);
+- p.pu[LUMA_8x32].addAvg = PFX(addAvg_8x32_neon);
+- p.pu[LUMA_12x16].addAvg = PFX(addAvg_12x16_neon);
+- p.pu[LUMA_16x4].addAvg = PFX(addAvg_16x4_neon);
+- p.pu[LUMA_16x8].addAvg = PFX(addAvg_16x8_neon);
+- p.pu[LUMA_16x12].addAvg = PFX(addAvg_16x12_neon);
+- p.pu[LUMA_16x16].addAvg = PFX(addAvg_16x16_neon);
+- p.pu[LUMA_16x32].addAvg = PFX(addAvg_16x32_neon);
+- p.pu[LUMA_16x64].addAvg = PFX(addAvg_16x64_neon);
+- p.pu[LUMA_24x32].addAvg = PFX(addAvg_24x32_neon);
+- p.pu[LUMA_32x8].addAvg = PFX(addAvg_32x8_neon);
+- p.pu[LUMA_32x16].addAvg = PFX(addAvg_32x16_neon);
+- p.pu[LUMA_32x24].addAvg = PFX(addAvg_32x24_neon);
+- p.pu[LUMA_32x32].addAvg = PFX(addAvg_32x32_neon);
+- p.pu[LUMA_32x64].addAvg = PFX(addAvg_32x64_neon);
+- p.pu[LUMA_48x64].addAvg = PFX(addAvg_48x64_neon);
+- p.pu[LUMA_64x16].addAvg = PFX(addAvg_64x16_neon);
+- p.pu[LUMA_64x32].addAvg = PFX(addAvg_64x32_neon);
+- p.pu[LUMA_64x48].addAvg = PFX(addAvg_64x48_neon);
+- p.pu[LUMA_64x64].addAvg = PFX(addAvg_64x64_neon);
++ p.pu[LUMA_4x4].addAvg[ALIGNED] = PFX(addAvg_4x4_neon);
++ p.pu[LUMA_4x8].addAvg[ALIGNED] = PFX(addAvg_4x8_neon);
++ p.pu[LUMA_4x16].addAvg[ALIGNED] = PFX(addAvg_4x16_neon);
++ p.pu[LUMA_8x4].addAvg[ALIGNED] = PFX(addAvg_8x4_neon);
++ p.pu[LUMA_8x8].addAvg[ALIGNED] = PFX(addAvg_8x8_neon);
++ p.pu[LUMA_8x16].addAvg[ALIGNED] = PFX(addAvg_8x16_neon);
++ p.pu[LUMA_8x32].addAvg[ALIGNED] = PFX(addAvg_8x32_neon);
++ p.pu[LUMA_12x16].addAvg[ALIGNED] = PFX(addAvg_12x16_neon);
++ p.pu[LUMA_16x4].addAvg[ALIGNED] = PFX(addAvg_16x4_neon);
++ p.pu[LUMA_16x8].addAvg[ALIGNED] = PFX(addAvg_16x8_neon);
++ p.pu[LUMA_16x12].addAvg[ALIGNED] = PFX(addAvg_16x12_neon);
++ p.pu[LUMA_16x16].addAvg[ALIGNED] = PFX(addAvg_16x16_neon);
++ p.pu[LUMA_16x32].addAvg[ALIGNED] = PFX(addAvg_16x32_neon);
++ p.pu[LUMA_16x64].addAvg[ALIGNED] = PFX(addAvg_16x64_neon);
++ p.pu[LUMA_24x32].addAvg[ALIGNED] = PFX(addAvg_24x32_neon);
++ p.pu[LUMA_32x8].addAvg[ALIGNED] = PFX(addAvg_32x8_neon);
++ p.pu[LUMA_32x16].addAvg[ALIGNED] = PFX(addAvg_32x16_neon);
++ p.pu[LUMA_32x24].addAvg[ALIGNED] = PFX(addAvg_32x24_neon);
++ p.pu[LUMA_32x32].addAvg[ALIGNED] = PFX(addAvg_32x32_neon);
++ p.pu[LUMA_32x64].addAvg[ALIGNED] = PFX(addAvg_32x64_neon);
++ p.pu[LUMA_48x64].addAvg[ALIGNED] = PFX(addAvg_48x64_neon);
++ p.pu[LUMA_64x16].addAvg[ALIGNED] = PFX(addAvg_64x16_neon);
++ p.pu[LUMA_64x32].addAvg[ALIGNED] = PFX(addAvg_64x32_neon);
++ p.pu[LUMA_64x48].addAvg[ALIGNED] = PFX(addAvg_64x48_neon);
++ p.pu[LUMA_64x64].addAvg[ALIGNED] = PFX(addAvg_64x64_neon);
+
+ // chroma addAvg
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_4x2].addAvg = PFX(addAvg_4x2_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_4x4].addAvg = PFX(addAvg_4x4_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_4x8].addAvg = PFX(addAvg_4x8_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_4x16].addAvg = PFX(addAvg_4x16_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_6x8].addAvg = PFX(addAvg_6x8_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_8x2].addAvg = PFX(addAvg_8x2_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_8x4].addAvg = PFX(addAvg_8x4_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_8x6].addAvg = PFX(addAvg_8x6_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_8x8].addAvg = PFX(addAvg_8x8_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_8x16].addAvg = PFX(addAvg_8x16_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_8x32].addAvg = PFX(addAvg_8x32_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_12x16].addAvg = PFX(addAvg_12x16_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_16x4].addAvg = PFX(addAvg_16x4_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_16x8].addAvg = PFX(addAvg_16x8_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_16x12].addAvg = PFX(addAvg_16x12_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_16x16].addAvg = PFX(addAvg_16x16_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_16x32].addAvg = PFX(addAvg_16x32_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_24x32].addAvg = PFX(addAvg_24x32_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_32x8].addAvg = PFX(addAvg_32x8_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_32x16].addAvg = PFX(addAvg_32x16_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_32x24].addAvg = PFX(addAvg_32x24_neon);
+- p.chroma[X265_CSP_I420].pu[CHROMA_420_32x32].addAvg = PFX(addAvg_32x32_neon);
+-
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_4x8].addAvg = PFX(addAvg_4x8_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_4x16].addAvg = PFX(addAvg_4x16_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_4x32].addAvg = PFX(addAvg_4x32_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_6x16].addAvg = PFX(addAvg_6x16_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_8x4].addAvg = PFX(addAvg_8x4_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_8x8].addAvg = PFX(addAvg_8x8_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_8x12].addAvg = PFX(addAvg_8x12_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_8x16].addAvg = PFX(addAvg_8x16_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_8x32].addAvg = PFX(addAvg_8x32_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_8x64].addAvg = PFX(addAvg_8x64_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_12x32].addAvg = PFX(addAvg_12x32_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_16x8].addAvg = PFX(addAvg_16x8_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_16x16].addAvg = PFX(addAvg_16x16_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_16x24].addAvg = PFX(addAvg_16x24_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_16x32].addAvg = PFX(addAvg_16x32_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_16x64].addAvg = PFX(addAvg_16x64_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_24x64].addAvg = PFX(addAvg_24x64_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_32x16].addAvg = PFX(addAvg_32x16_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_32x32].addAvg = PFX(addAvg_32x32_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_32x48].addAvg = PFX(addAvg_32x48_neon);
+- p.chroma[X265_CSP_I422].pu[CHROMA_422_32x64].addAvg = PFX(addAvg_32x64_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_4x2].addAvg[ALIGNED] = PFX(addAvg_4x2_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_4x4].addAvg[ALIGNED] = PFX(addAvg_4x4_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_4x8].addAvg[ALIGNED] = PFX(addAvg_4x8_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_4x16].addAvg[ALIGNED] = PFX(addAvg_4x16_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_6x8].addAvg[ALIGNED] = PFX(addAvg_6x8_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_8x2].addAvg[ALIGNED] = PFX(addAvg_8x2_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_8x4].addAvg[ALIGNED] = PFX(addAvg_8x4_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_8x6].addAvg[ALIGNED] = PFX(addAvg_8x6_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_8x8].addAvg[ALIGNED] = PFX(addAvg_8x8_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_8x16].addAvg[ALIGNED] = PFX(addAvg_8x16_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_8x32].addAvg[ALIGNED] = PFX(addAvg_8x32_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_12x16].addAvg[ALIGNED] = PFX(addAvg_12x16_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_16x4].addAvg[ALIGNED] = PFX(addAvg_16x4_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_16x8].addAvg[ALIGNED] = PFX(addAvg_16x8_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_16x12].addAvg[ALIGNED] = PFX(addAvg_16x12_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_16x16].addAvg[ALIGNED] = PFX(addAvg_16x16_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_16x32].addAvg[ALIGNED] = PFX(addAvg_16x32_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_24x32].addAvg[ALIGNED] = PFX(addAvg_24x32_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_32x8].addAvg[ALIGNED] = PFX(addAvg_32x8_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_32x16].addAvg[ALIGNED] = PFX(addAvg_32x16_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_32x24].addAvg[ALIGNED] = PFX(addAvg_32x24_neon);
++ p.chroma[X265_CSP_I420].pu[CHROMA_420_32x32].addAvg[ALIGNED] = PFX(addAvg_32x32_neon);
++
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_4x8].addAvg[ALIGNED] = PFX(addAvg_4x8_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_4x16].addAvg[ALIGNED] = PFX(addAvg_4x16_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_4x32].addAvg[ALIGNED] = PFX(addAvg_4x32_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_6x16].addAvg[ALIGNED] = PFX(addAvg_6x16_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_8x4].addAvg[ALIGNED] = PFX(addAvg_8x4_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_8x8].addAvg[ALIGNED] = PFX(addAvg_8x8_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_8x12].addAvg[ALIGNED] = PFX(addAvg_8x12_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_8x16].addAvg[ALIGNED] = PFX(addAvg_8x16_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_8x32].addAvg[ALIGNED] = PFX(addAvg_8x32_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_8x64].addAvg[ALIGNED] = PFX(addAvg_8x64_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_12x32].addAvg[ALIGNED] = PFX(addAvg_12x32_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_16x8].addAvg[ALIGNED] = PFX(addAvg_16x8_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_16x16].addAvg[ALIGNED] = PFX(addAvg_16x16_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_16x24].addAvg[ALIGNED] = PFX(addAvg_16x24_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_16x32].addAvg[ALIGNED] = PFX(addAvg_16x32_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_16x64].addAvg[ALIGNED] = PFX(addAvg_16x64_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_24x64].addAvg[ALIGNED] = PFX(addAvg_24x64_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_32x16].addAvg[ALIGNED] = PFX(addAvg_32x16_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_32x32].addAvg[ALIGNED] = PFX(addAvg_32x32_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_32x48].addAvg[ALIGNED] = PFX(addAvg_32x48_neon);
++ p.chroma[X265_CSP_I422].pu[CHROMA_422_32x64].addAvg[ALIGNED] = PFX(addAvg_32x64_neon);
+
+ // quant
+ p.quant = PFX(quant_neon);
+@@ -402,7 +402,7 @@ void setupAssemblyPrimitives(EncoderPrim
+ p.scale2D_64to32 = PFX(scale2D_64to32_neon);
+
+ // scale1D_128to64
+- p.scale1D_128to64 = PFX(scale1D_128to64_neon);
++ p.scale1D_128to64[ALIGNED] = PFX(scale1D_128to64_neon);
+
+ // copy_count
+ p.cu[BLOCK_4x4].copy_cnt = PFX(copy_cnt_4_neon);
+@@ -411,37 +411,37 @@ void setupAssemblyPrimitives(EncoderPrim
+ p.cu[BLOCK_32x32].copy_cnt = PFX(copy_cnt_32_neon);
+
+ // filterPixelToShort
+- p.pu[LUMA_4x4].convert_p2s = PFX(filterPixelToShort_4x4_neon);
+- p.pu[LUMA_4x8].convert_p2s = PFX(filterPixelToShort_4x8_neon);
+- p.pu[LUMA_4x16].convert_p2s = PFX(filterPixelToShort_4x16_neon);
+- p.pu[LUMA_8x4].convert_p2s = PFX(filterPixelToShort_8x4_neon);
+- p.pu[LUMA_8x8].convert_p2s = PFX(filterPixelToShort_8x8_neon);
+- p.pu[LUMA_8x16].convert_p2s = PFX(filterPixelToShort_8x16_neon);
+- p.pu[LUMA_8x32].convert_p2s = PFX(filterPixelToShort_8x32_neon);
+- p.pu[LUMA_12x16].convert_p2s = PFX(filterPixelToShort_12x16_neon);
+- p.pu[LUMA_16x4].convert_p2s = PFX(filterPixelToShort_16x4_neon);
+- p.pu[LUMA_16x8].convert_p2s = PFX(filterPixelToShort_16x8_neon);
+- p.pu[LUMA_16x12].convert_p2s = PFX(filterPixelToShort_16x12_neon);
+- p.pu[LUMA_16x16].convert_p2s = PFX(filterPixelToShort_16x16_neon);
+- p.pu[LUMA_16x32].convert_p2s = PFX(filterPixelToShort_16x32_neon);
+- p.pu[LUMA_16x64].convert_p2s = PFX(filterPixelToShort_16x64_neon);
+- p.pu[LUMA_24x32].convert_p2s = PFX(filterPixelToShort_24x32_neon);
+- p.pu[LUMA_32x8].convert_p2s = PFX(filterPixelToShort_32x8_neon);
+- p.pu[LUMA_32x16].convert_p2s = PFX(filterPixelToShort_32x16_neon);
+- p.pu[LUMA_32x24].convert_p2s = PFX(filterPixelToShort_32x24_neon);
+- p.pu[LUMA_32x32].convert_p2s = PFX(filterPixelToShort_32x32_neon);
+- p.pu[LUMA_32x64].convert_p2s = PFX(filterPixelToShort_32x64_neon);
+- p.pu[LUMA_48x64].convert_p2s = PFX(filterPixelToShort_48x64_neon);
+- p.pu[LUMA_64x16].convert_p2s = PFX(filterPixelToShort_64x16_neon);
+- p.pu[LUMA_64x32].convert_p2s = PFX(filterPixelToShort_64x32_neon);
+- p.pu[LUMA_64x48].convert_p2s = PFX(filterPixelToShort_64x48_neon);
+- p.pu[LUMA_64x64].convert_p2s = PFX(filterPixelToShort_64x64_neon);
++ p.pu[LUMA_4x4].convert_p2s[ALIGNED] = PFX(filterPixelToShort_4x4_neon);
++ p.pu[LUMA_4x8].convert_p2s[ALIGNED] = PFX(filterPixelToShort_4x8_neon);
++ p.pu[LUMA_4x16].convert_p2s[ALIGNED] = PFX(filterPixelToShort_4x16_neon);
++ p.pu[LUMA_8x4].convert_p2s[ALIGNED] = PFX(filterPixelToShort_8x4_neon);
++ p.pu[LUMA_8x8].convert_p2s[ALIGNED] = PFX(filterPixelToShort_8x8_neon);
++ p.pu[LUMA_8x16].convert_p2s[ALIGNED] = PFX(filterPixelToShort_8x16_neon);
++ p.pu[LUMA_8x32].convert_p2s[ALIGNED] = PFX(filterPixelToShort_8x32_neon);
++ p.pu[LUMA_12x16].convert_p2s[ALIGNED] = PFX(filterPixelToShort_12x16_neon);
++ p.pu[LUMA_16x4].convert_p2s[ALIGNED] = PFX(filterPixelToShort_16x4_neon);
++ p.pu[LUMA_16x8].convert_p2s[ALIGNED] = PFX(filterPixelToShort_16x8_neon);
++ p.pu[LUMA_16x12].convert_p2s[ALIGNED] = PFX(filterPixelToShort_16x12_neon);
++ p.pu[LUMA_16x16].convert_p2s[ALIGNED] = PFX(filterPixelToShort_16x16_neon);
++ p.pu[LUMA_16x32].convert_p2s[ALIGNED] = PFX(filterPixelToShort_16x32_neon);
++ p.pu[LUMA_16x64].convert_p2s[ALIGNED] = PFX(filterPixelToShort_16x64_neon);
++ p.pu[LUMA_24x32].convert_p2s[ALIGNED] = PFX(filterPixelToShort_24x32_neon);
++ p.pu[LUMA_32x8].convert_p2s[ALIGNED] = PFX(filterPixelToShort_32x8_neon);
++ p.pu[LUMA_32x16].convert_p2s[ALIGNED] = PFX(filterPixelToShort_32x16_neon);
++ p.pu[LUMA_32x24].convert_p2s[ALIGNED] = PFX(filterPixelToShort_32x24_neon);
++ p.pu[LUMA_32x32].convert_p2s[ALIGNED] = PFX(filterPixelToShort_32x32_neon);
++ p.pu[LUMA_32x64].convert_p2s[ALIGNED] = PFX(filterPixelToShort_32x64_neon);
++ p.pu[LUMA_48x64].convert_p2s[ALIGNED] = PFX(filterPixelToShort_48x64_neon);
++ p.pu[LUMA_64x16].convert_p2s[ALIGNED] = PFX(filterPixelToShort_64x16_neon);
++ p.pu[LUMA_64x32].convert_p2s[ALIGNED] = PFX(filterPixelToShort_64x32_neon);
++ p.pu[LUMA_64x48].convert_p2s[ALIGNED] = PFX(filterPixelToShort_64x48_neon);
++ p.pu[LUMA_64x64].convert_p2s[ALIGNED] = PFX(filterPixelToShort_64x64_neon);
+
+ // Block_fill
+- p.cu[BLOCK_4x4].blockfill_s = PFX(blockfill_s_4x4_neon);
+- p.cu[BLOCK_8x8].blockfill_s = PFX(blockfill_s_8x8_neon);
+- p.cu[BLOCK_16x16].blockfill_s = PFX(blockfill_s_16x16_neon);
+- p.cu[BLOCK_32x32].blockfill_s = PFX(blockfill_s_32x32_neon);
++ p.cu[BLOCK_4x4].blockfill_s[ALIGNED] = PFX(blockfill_s_4x4_neon);
++ p.cu[BLOCK_8x8].blockfill_s[ALIGNED] = PFX(blockfill_s_8x8_neon);
++ p.cu[BLOCK_16x16].blockfill_s[ALIGNED] = PFX(blockfill_s_16x16_neon);
++ p.cu[BLOCK_32x32].blockfill_s[ALIGNED] = PFX(blockfill_s_32x32_neon);
+
+ // Blockcopy_ss
+ p.cu[BLOCK_4x4].copy_ss = PFX(blockcopy_ss_4x4_neon);
+@@ -495,21 +495,21 @@ void setupAssemblyPrimitives(EncoderPrim
+ p.chroma[X265_CSP_I422].cu[BLOCK_422_32x64].copy_sp = PFX(blockcopy_sp_32x64_neon);
+
+ // pixel_add_ps
+- p.cu[BLOCK_4x4].add_ps = PFX(pixel_add_ps_4x4_neon);
+- p.cu[BLOCK_8x8].add_ps = PFX(pixel_add_ps_8x8_neon);
+- p.cu[BLOCK_16x16].add_ps = PFX(pixel_add_ps_16x16_neon);
+- p.cu[BLOCK_32x32].add_ps = PFX(pixel_add_ps_32x32_neon);
+- p.cu[BLOCK_64x64].add_ps = PFX(pixel_add_ps_64x64_neon);
++ p.cu[BLOCK_4x4].add_ps[ALIGNED] = PFX(pixel_add_ps_4x4_neon);
++ p.cu[BLOCK_8x8].add_ps[ALIGNED] = PFX(pixel_add_ps_8x8_neon);
++ p.cu[BLOCK_16x16].add_ps[ALIGNED] = PFX(pixel_add_ps_16x16_neon);
++ p.cu[BLOCK_32x32].add_ps[ALIGNED] = PFX(pixel_add_ps_32x32_neon);
++ p.cu[BLOCK_64x64].add_ps[ALIGNED] = PFX(pixel_add_ps_64x64_neon);
+
+ // chroma add_ps
+- p.chroma[X265_CSP_I420].cu[BLOCK_420_4x4].add_ps = PFX(pixel_add_ps_4x4_neon);
+- p.chroma[X265_CSP_I420].cu[BLOCK_420_8x8].add_ps = PFX(pixel_add_ps_8x8_neon);
+- p.chroma[X265_CSP_I420].cu[BLOCK_420_16x16].add_ps = PFX(pixel_add_ps_16x16_neon);
+- p.chroma[X265_CSP_I420].cu[BLOCK_420_32x32].add_ps = PFX(pixel_add_ps_32x32_neon);
+- p.chroma[X265_CSP_I422].cu[BLOCK_422_4x8].add_ps = PFX(pixel_add_ps_4x8_neon);
+- p.chroma[X265_CSP_I422].cu[BLOCK_422_8x16].add_ps = PFX(pixel_add_ps_8x16_neon);
+- p.chroma[X265_CSP_I422].cu[BLOCK_422_16x32].add_ps = PFX(pixel_add_ps_16x32_neon);
+- p.chroma[X265_CSP_I422].cu[BLOCK_422_32x64].add_ps = PFX(pixel_add_ps_32x64_neon);
++ p.chroma[X265_CSP_I420].cu[BLOCK_420_4x4].add_ps[ALIGNED] = PFX(pixel_add_ps_4x4_neon);
++ p.chroma[X265_CSP_I420].cu[BLOCK_420_8x8].add_ps[ALIGNED] = PFX(pixel_add_ps_8x8_neon);
++ p.chroma[X265_CSP_I420].cu[BLOCK_420_16x16].add_ps[ALIGNED] = PFX(pixel_add_ps_16x16_neon);
++ p.chroma[X265_CSP_I420].cu[BLOCK_420_32x32].add_ps[ALIGNED] = PFX(pixel_add_ps_32x32_neon);
++ p.chroma[X265_CSP_I422].cu[BLOCK_422_4x8].add_ps[ALIGNED] = PFX(pixel_add_ps_4x8_neon);
++ p.chroma[X265_CSP_I422].cu[BLOCK_422_8x16].add_ps[ALIGNED] = PFX(pixel_add_ps_8x16_neon);
++ p.chroma[X265_CSP_I422].cu[BLOCK_422_16x32].add_ps[ALIGNED] = PFX(pixel_add_ps_16x32_neon);
++ p.chroma[X265_CSP_I422].cu[BLOCK_422_32x64].add_ps[ALIGNED] = PFX(pixel_add_ps_32x64_neon);
+
+ // cpy2Dto1D_shr
+ p.cu[BLOCK_4x4].cpy2Dto1D_shr = PFX(cpy2Dto1D_shr_4x4_neon);
+@@ -518,10 +518,10 @@ void setupAssemblyPrimitives(EncoderPrim
+ p.cu[BLOCK_32x32].cpy2Dto1D_shr = PFX(cpy2Dto1D_shr_32x32_neon);
+
+ // ssd_s
+- p.cu[BLOCK_4x4].ssd_s = PFX(pixel_ssd_s_4x4_neon);
+- p.cu[BLOCK_8x8].ssd_s = PFX(pixel_ssd_s_8x8_neon);
+- p.cu[BLOCK_16x16].ssd_s = PFX(pixel_ssd_s_16x16_neon);
+- p.cu[BLOCK_32x32].ssd_s = PFX(pixel_ssd_s_32x32_neon);
++ p.cu[BLOCK_4x4].ssd_s[ALIGNED] = PFX(pixel_ssd_s_4x4_neon);
++ p.cu[BLOCK_8x8].ssd_s[ALIGNED] = PFX(pixel_ssd_s_8x8_neon);
++ p.cu[BLOCK_16x16].ssd_s[ALIGNED] = PFX(pixel_ssd_s_16x16_neon);
++ p.cu[BLOCK_32x32].ssd_s[ALIGNED] = PFX(pixel_ssd_s_32x32_neon);
+
+ // sse_ss
+ p.cu[BLOCK_4x4].sse_ss = PFX(pixel_sse_ss_4x4_neon);
+@@ -548,10 +548,10 @@ void setupAssemblyPrimitives(EncoderPrim
+ p.chroma[X265_CSP_I422].cu[BLOCK_422_32x64].sub_ps = PFX(pixel_sub_ps_32x64_neon);
+
+ // calc_Residual
+- p.cu[BLOCK_4x4].calcresidual = PFX(getResidual4_neon);
+- p.cu[BLOCK_8x8].calcresidual = PFX(getResidual8_neon);
+- p.cu[BLOCK_16x16].calcresidual = PFX(getResidual16_neon);
+- p.cu[BLOCK_32x32].calcresidual = PFX(getResidual32_neon);
++ p.cu[BLOCK_4x4].calcresidual[ALIGNED] = PFX(getResidual4_neon);
++ p.cu[BLOCK_8x8].calcresidual[ALIGNED] = PFX(getResidual8_neon);
++ p.cu[BLOCK_16x16].calcresidual[ALIGNED] = PFX(getResidual16_neon);
++ p.cu[BLOCK_32x32].calcresidual[ALIGNED] = PFX(getResidual32_neon);
+
+ // sse_pp
+ p.cu[BLOCK_4x4].sse_pp = PFX(pixel_sse_pp_4x4_neon);
+@@ -722,31 +722,31 @@ void setupAssemblyPrimitives(EncoderPrim
+ p.pu[LUMA_64x64].sad_x4 = PFX(sad_x4_64x64_neon);
+
+ // pixel_avg_pp
+- p.pu[LUMA_4x4].pixelavg_pp = PFX(pixel_avg_pp_4x4_neon);
+- p.pu[LUMA_4x8].pixelavg_pp = PFX(pixel_avg_pp_4x8_neon);
+- p.pu[LUMA_4x16].pixelavg_pp = PFX(pixel_avg_pp_4x16_neon);
+- p.pu[LUMA_8x4].pixelavg_pp = PFX(pixel_avg_pp_8x4_neon);
+- p.pu[LUMA_8x8].pixelavg_pp = PFX(pixel_avg_pp_8x8_neon);
+- p.pu[LUMA_8x16].pixelavg_pp = PFX(pixel_avg_pp_8x16_neon);
+- p.pu[LUMA_8x32].pixelavg_pp = PFX(pixel_avg_pp_8x32_neon);
+- p.pu[LUMA_12x16].pixelavg_pp = PFX(pixel_avg_pp_12x16_neon);
+- p.pu[LUMA_16x4].pixelavg_pp = PFX(pixel_avg_pp_16x4_neon);
+- p.pu[LUMA_16x8].pixelavg_pp = PFX(pixel_avg_pp_16x8_neon);
+- p.pu[LUMA_16x12].pixelavg_pp = PFX(pixel_avg_pp_16x12_neon);
+- p.pu[LUMA_16x16].pixelavg_pp = PFX(pixel_avg_pp_16x16_neon);
+- p.pu[LUMA_16x32].pixelavg_pp = PFX(pixel_avg_pp_16x32_neon);
+- p.pu[LUMA_16x64].pixelavg_pp = PFX(pixel_avg_pp_16x64_neon);
+- p.pu[LUMA_24x32].pixelavg_pp = PFX(pixel_avg_pp_24x32_neon);
+- p.pu[LUMA_32x8].pixelavg_pp = PFX(pixel_avg_pp_32x8_neon);
+- p.pu[LUMA_32x16].pixelavg_pp = PFX(pixel_avg_pp_32x16_neon);
+- p.pu[LUMA_32x24].pixelavg_pp = PFX(pixel_avg_pp_32x24_neon);
+- p.pu[LUMA_32x32].pixelavg_pp = PFX(pixel_avg_pp_32x32_neon);
+- p.pu[LUMA_32x64].pixelavg_pp = PFX(pixel_avg_pp_32x64_neon);
+- p.pu[LUMA_48x64].pixelavg_pp = PFX(pixel_avg_pp_48x64_neon);
+- p.pu[LUMA_64x16].pixelavg_pp = PFX(pixel_avg_pp_64x16_neon);
+- p.pu[LUMA_64x32].pixelavg_pp = PFX(pixel_avg_pp_64x32_neon);
+- p.pu[LUMA_64x48].pixelavg_pp = PFX(pixel_avg_pp_64x48_neon);
+- p.pu[LUMA_64x64].pixelavg_pp = PFX(pixel_avg_pp_64x64_neon);
++ p.pu[LUMA_4x4].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_4x4_neon);
++ p.pu[LUMA_4x8].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_4x8_neon);
++ p.pu[LUMA_4x16].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_4x16_neon);
++ p.pu[LUMA_8x4].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_8x4_neon);
++ p.pu[LUMA_8x8].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_8x8_neon);
++ p.pu[LUMA_8x16].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_8x16_neon);
++ p.pu[LUMA_8x32].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_8x32_neon);
++ p.pu[LUMA_12x16].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_12x16_neon);
++ p.pu[LUMA_16x4].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_16x4_neon);
++ p.pu[LUMA_16x8].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_16x8_neon);
++ p.pu[LUMA_16x12].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_16x12_neon);
++ p.pu[LUMA_16x16].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_16x16_neon);
++ p.pu[LUMA_16x32].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_16x32_neon);
++ p.pu[LUMA_16x64].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_16x64_neon);
++ p.pu[LUMA_24x32].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_24x32_neon);
++ p.pu[LUMA_32x8].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_32x8_neon);
++ p.pu[LUMA_32x16].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_32x16_neon);
++ p.pu[LUMA_32x24].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_32x24_neon);
++ p.pu[LUMA_32x32].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_32x32_neon);
++ p.pu[LUMA_32x64].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_32x64_neon);
++ p.pu[LUMA_48x64].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_48x64_neon);
++ p.pu[LUMA_64x16].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_64x16_neon);
++ p.pu[LUMA_64x32].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_64x32_neon);
++ p.pu[LUMA_64x48].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_64x48_neon);
++ p.pu[LUMA_64x64].pixelavg_pp[ALIGNED] = PFX(pixel_avg_pp_64x64_neon);
+
+ // planecopy
+ p.planecopy_cp = PFX(pixel_planecopy_cp_neon);
diff --git a/gnu/packages/patches/xapian-revert-5489fb2f8.patch b/gnu/packages/patches/xapian-revert-5489fb2f8.patch
new file mode 100644
index 0000000000..7b78e2abb5
--- /dev/null
+++ b/gnu/packages/patches/xapian-revert-5489fb2f8.patch
@@ -0,0 +1,23 @@
+Revert this upstream commit which breaks a test case in "notmuch":
+
+https://git.xapian.org/?p=xapian;a=commitdiff;h=5489fb2f838c0f0b0a593b4c17df282a93a1fe5a
+
+See the notmuch FAQ entry:
+
+https://notmuchmail.org/faq/#index12h2
+
+This should be fixed for later releases.
+
+diff --git a/backends/glass/glass_postlist.cc b/xapian-core/backends/glass/glass_postlist.cc
+index 80e578b85..a47f14a68 100644
+--- a/backends/glass/glass_postlist.cc
++++ b/backends/glass/glass_postlist.cc
+@@ -759,7 +759,7 @@ GlassPostList::open_nearby_postlist(const std::string & term_,
+ (void)need_pos;
+ if (term_.empty())
+ RETURN(NULL);
+- if (!this_db.get() || this_db->postlist_table.is_modified())
++ if (!this_db.get() || this_db->postlist_table.is_writable())
+ RETURN(NULL);
+ RETURN(new GlassPostList(this_db, term_, cursor->clone()));
+ }
diff --git a/gnu/packages/patches/xorg-server-rotate-fb.patch b/gnu/packages/patches/xorg-server-rotate-fb.patch
new file mode 100644
index 0000000000..f47036b2a7
--- /dev/null
+++ b/gnu/packages/patches/xorg-server-rotate-fb.patch
@@ -0,0 +1,35 @@
+commit a85e94a50c94b07574c8701a3ff3c1243f4257f4
+Author: Olivier Fourdan <ofourdan@redhat.com>
+Date: Fri Jun 15 08:57:12 2018 +0200
+
+ modesetting: use drmmode_bo_import() for rotate_fb
+
+ drmmode_shadow_allocate() still uses drmModeAddFB() which may fail if
+ the format is not as expected, preventing from using a rotated output.
+
+ Change it to use the new function drmmode_bo_import() which takes care
+ of calling the drmModeAddFB2() API.
+
+ Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=106715
+ Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
+ Tested-by: Tomas Pelka <tpelka@redhat.com>
+ Reviewed-by: Lyude Paul <lyude@redhat.com>
+
+diff --git a/hw/xfree86/drivers/modesetting/drmmode_display.c b/hw/xfree86/drivers/modesetting/drmmode_display.c
+index 859a21a9d..ec11b3f56 100644
+--- a/hw/xfree86/drivers/modesetting/drmmode_display.c
++++ b/hw/xfree86/drivers/modesetting/drmmode_display.c
+@@ -1794,11 +1794,8 @@ drmmode_shadow_allocate(xf86CrtcPtr crtc, int width, int height)
+ return NULL;
+ }
+
+- ret = drmModeAddFB(drmmode->fd, width, height, crtc->scrn->depth,
+- drmmode->kbpp,
+- drmmode_bo_get_pitch(&drmmode_crtc->rotate_bo),
+- drmmode_bo_get_handle(&drmmode_crtc->rotate_bo),
+- &drmmode_crtc->rotate_fb_id);
++ ret = drmmode_bo_import(drmmode, &drmmode_crtc->rotate_bo,
++ &drmmode_crtc->rotate_fb_id);
+
+ if (ret) {
+ ErrorF("failed to add rotate fb\n");